container

package module
v0.0.0-...-7ca360d Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2018 License: MIT Imports: 11 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

container

The library for building containers.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Execve

func Execve(command string, args []string, env ...[]string)

func IsInitProcess

func IsInitProcess() bool

func MountBasicFileSystems

func MountBasicFileSystems()

func NewInitProcess

func NewInitProcess(ns *Namespace, tty bool, command string, arguments ...string) *exec.Cmd

func NewOrLoadCgroups

func NewOrLoadCgroups(hierarchy cgroups.Hierarchy, path cgroups.Path, resources *specs.LinuxResources) (cgroups.Cgroup, error)

func ParseInit

func ParseInit() (command string, args []string)

Schedule Init Process

func PivotRoot

func PivotRoot(root string) error

Types

type AUFS

type AUFS struct {
	Config   *AUFSConfig
	BasePath string
}

func NewAUFS

func NewAUFS(basePath string) *AUFS

func (*AUFS) GetLayerPath

func (aufs *AUFS) GetLayerPath(name string) string

func (*AUFS) Mount

func (aufs *AUFS) Mount(topLayer string, path string, additionalLayers ...string) error

func (*AUFS) NewImageLayer

func (aufs *AUFS) NewImageLayer(name string) *AUFS

func (*AUFS) NewLayer

func (aufs *AUFS) NewLayer(name string) *AUFS

func (*AUFS) RemoveLayer

func (aufs *AUFS) RemoveLayer(name string) *AUFS

func (*AUFS) WriteConfig

func (aufs *AUFS) WriteConfig() *AUFS

type AUFSConfig

type AUFSConfig struct {
	Layers      []string
	ImageLayers []string
}

type Namespace

type Namespace struct {
	Cloneflags uintptr
	P_PS1      string
	P_UID      int
	P_GID      int
}

func NewNS

func NewNS() *Namespace

func (*Namespace) ApplyIPC

func (ns *Namespace) ApplyIPC() *Namespace

func (*Namespace) ApplyMount

func (ns *Namespace) ApplyMount() *Namespace

func (*Namespace) ApplyNet

func (ns *Namespace) ApplyNet() *Namespace

func (*Namespace) ApplyPID

func (ns *Namespace) ApplyPID() *Namespace

func (*Namespace) ApplyUTS

func (ns *Namespace) ApplyUTS() *Namespace

func (*Namespace) ApplyUser

func (ns *Namespace) ApplyUser() *Namespace

func (*Namespace) Command

func (ns *Namespace) Command(cmdl string, arg ...string) *exec.Cmd

func (*Namespace) RedirectStd

func (ns *Namespace) RedirectStd(cmd *exec.Cmd) *exec.Cmd

func (*Namespace) SetPS1

func (ns *Namespace) SetPS1(name string) *Namespace

func (*Namespace) SetUID

func (ns *Namespace) SetUID(uid int, gid int) *Namespace

Directories

Path Synopsis
cmd
aufs command

Jump to

Keyboard shortcuts

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