Documentation
¶
Index ¶
- Constants
- Variables
- func FindCgroupMountpoint(cgroupPath, subsystem string) (string, error)
- func FindCgroupMountpointAndRoot(cgroupPath, subsystem string) (string, string, error)
- func GetInitCgroup(subsystem string) (string, error)
- func GetInitCgroupPath(subsystem string) (string, error)
- func GetOwnCgroup(subsystem string) (string, error)
- func GetOwnCgroupPath(subsystem string) (string, error)
- func IsNotFound(err error) bool
- func NewNotFoundError(sub string) error
- func OpenFile(dir, file string, flags int) (*os.File, error)
- func ReadFile(dir, file string) (string, error)
- func WriteFile(dir, file, data string) error
- type NotFoundError
Constants ¶
View Source
const (
CgroupNamePrefix = "name="
)
Variables ¶
View Source
var (
ErrV1NoUnified = errors.New("invalid configuration: cannot use unified on cgroup v1")
)
View Source
var ( // TestMode is set to true by unit tests that need "fake" cgroupfs. TestMode bool )
Functions ¶
func GetInitCgroup ¶
func GetInitCgroupPath ¶
func GetOwnCgroup ¶
GetOwnCgroup returns the relative path to the cgroup docker is running in.
func GetOwnCgroupPath ¶
func IsNotFound ¶
func NewNotFoundError ¶
func OpenFile ¶
OpenFile opens a cgroup file in a given dir with given flags. It is supposed to be used for cgroup files only.
Types ¶
type NotFoundError ¶
type NotFoundError struct {
Subsystem string
}
func (*NotFoundError) Error ¶
func (e *NotFoundError) Error() string
Directories
¶
| Path | Synopsis |
|---|---|
|
devicefilter
Package devicefilter contains eBPF device filter program The implementation is based on https://github.com/containers/crun/blob/0.10.2/src/libcrun/ebpf.c Although ebpf.c is originally licensed under LGPL-3.0-or-later, the author (Giuseppe Scrivano) agreed to relicense the file in Apache License 2.0: https://github.com/opencontainers/runc/issues/2144#issuecomment-543116397
|
Package devicefilter contains eBPF device filter program The implementation is based on https://github.com/containers/crun/blob/0.10.2/src/libcrun/ebpf.c Although ebpf.c is originally licensed under LGPL-3.0-or-later, the author (Giuseppe Scrivano) agreed to relicense the file in Apache License 2.0: https://github.com/opencontainers/runc/issues/2144#issuecomment-543116397 |
Click to show internal directories.
Click to hide internal directories.