kubernetesk8s.io/kubernetes/pkg/util/procfs Index | Files

package procfs

import "k8s.io/kubernetes/pkg/util/procfs"

Package procfs implements utility functions relating to the /proc mount.

Index

Types

type FakeProcFs

type FakeProcFs struct{}

func (*FakeProcFs) GetFullContainerName

func (fakePfs *FakeProcFs) GetFullContainerName(pid int) (string, error)

getFullContainerName gets the container name given the root process id of the container. Eg. If the devices cgroup for the container is stored in /sys/fs/cgroup/devices/docker/nginx, return docker/nginx. Assumes that the process is part of exactly one cgroup hierarchy.

type ProcFs

type ProcFs struct{}

func (*ProcFs) GetFullContainerName

func (pfs *ProcFs) GetFullContainerName(pid int) (string, error)

getFullContainerName gets the container name given the root process id of the container. Eg. If the devices cgroup for the container is stored in /sys/fs/cgroup/devices/docker/nginx, return docker/nginx. Assumes that the process is part of exactly one cgroup hierarchy.

type ProcFsInterface

type ProcFsInterface interface {
	// getFullContainerName gets the container name given the root process id of the container.
	GetFullContainerName(pid int) (string, error)
}

func NewFakeProcFs

func NewFakeProcFs() ProcFsInterface

func NewProcFs

func NewProcFs() ProcFsInterface

Source Files

doc.go procfs.go procfs_fake.go procfs_interface.go

Version
v1.1.9-beta.0
Published
Feb 23, 2016
Platform
js/wasm
Imports
5 packages
Last checked
3 minutes ago

Tools for package owners.