disk

package
v0.2.16 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 11, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package disk reports free space on a runner host's image store. It stats the filesystem rather than summing file sizes: VM disk images are sparse, so what they appear to hold bears no relation to the blocks they occupy.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Usage

type Usage struct {
	Free  uint64
	Total uint64
}

Usage is a filesystem's available and total capacity in bytes. Free counts only blocks available to an unprivileged writer — the reserve root can still dip into can't run a job.

func Stat

func Stat(path string) (Usage, error)

Stat reports usage for the filesystem holding path. A path that doesn't exist yet — an image store before the first pull — is measured at its nearest existing ancestor.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL