Documentation ¶
Index ¶
- func CheckFilePath(path string) (string, error)
- func DefaultNamespace() (string, error)
- func FindAvailablePort() int
- func GenerateContainerName(namespace, vmname string) string
- func GetDefaultWorkDir() string
- func GetUserHomePath() string
- func ParseContainerName(contname string) (ns, vmname string, err error)
- func RandomName() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckFilePath ¶
CheckFilePath verifies and fixes a file path
func DefaultNamespace ¶
DefaultNamespace returns the default namespace for a user, which generally is the user's username.
func GenerateContainerName ¶
GenerateContainerName generates a container name based on the namespace and virtual machine name.
func GetDefaultWorkDir ¶
func GetDefaultWorkDir() string
GetDefaultWorkDir returns the default working directory
func ParseContainerName ¶
ParseContainerName takes a container name and returns the VM namespace and name, or an error if the container name is incorrectly formatted.
func RandomName ¶
func RandomName() string
RandomName returns a randomly generated name. This just wraps docker's namesgenerator.GetRandomName() to avoid extra imports.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.