Documentation ¶
Index ¶
- Variables
- func CreateMountPoint(containerName, imageName string) error
- func CreateReadOnlyLayer(imageName string) error
- func CreateWriteLayer(containerName string)
- func DeleteMountPoint(containerName string) error
- func DeleteVolume(volumeURLs []string, containerName string) error
- func DeleteWorkSpace(volume, containerName string)
- func DeleteWriteLayer(containerName string)
- func MountVolume(volumeURLs []string, containerName string) error
- func NewParentProcess(tty bool, containerName, volume, imageName string, envSlice []string) (*exec.Cmd, *os.File)
- func NewPipe() (*os.File, *os.File, error)
- func NewWorkSpace(volume, imageName, containerName string)
- func PathExists(path string) (bool, error)
- func RunContainerInitProcess() error
- type ContainerInfo
Constants ¶
This section is empty.
Variables ¶
View Source
var ( RUNNING string = "running" STOP string = "stopped" Exit string = "exited" DefaultInfoLocation string = "/var/run/mydocker/%s/" ConfigName string = "config.json" ContainerLogFile string = "container.log" RootUrl string = "/root" MntUrl string = "/root/mnt/%s" WriteLayerUrl string = "/root/writeLayer/%s" )
Functions ¶
func CreateMountPoint ¶
func CreateWriteLayer ¶
func CreateWriteLayer(containerName string)
func DeleteMountPoint ¶
func DeleteVolume ¶
func DeleteWorkSpace ¶
func DeleteWorkSpace(volume, containerName string)
Delete the AUFS filesystem while container exit
func DeleteWriteLayer ¶
func DeleteWriteLayer(containerName string)
func MountVolume ¶
func NewParentProcess ¶
func NewWorkSpace ¶
func NewWorkSpace(volume, imageName, containerName string)
Create a AUFS filesystem as container root workspace
func PathExists ¶
func RunContainerInitProcess ¶
func RunContainerInitProcess() error
Types ¶
type ContainerInfo ¶
type ContainerInfo struct { Pid string `json:"pid"` //容器的init进程在宿主机上的 PID Id string `json:"id"` //容器Id Name string `json:"name"` //容器名 Command string `json:"command"` //容器内init运行命令 CreatedTime string `json:"createTime"` //创建时间 Status string `json:"status"` //容器的状态 Volume string `json:"volume"` //容器的数据卷 PortMapping []string `json:"portmapping"` //端口映射 }
Click to show internal directories.
Click to hide internal directories.