Versions in this module Expand all Collapse all v4 v4.1.2 Jun 10, 2022 v4.1.1 Jun 10, 2022 Changes in this version + var ErrInvalidPodSpecConfig = errors.New("invalid pod spec") + var ErrInvalidSpecConfig = errors.New("invalid configuration") + var ErrNoStaticIPRootless error = errors.New("rootless containers and pods cannot be assigned static IP addresses") + var ErrNoStaticMACRootless error = errors.New("rootless containers and pods cannot be assigned static MAC addresses") + var ImageVolumeModeValues = []string + var SdNotifyModeValues = []string + var SystemDValues = []string + func ConvertWinMountPath(path string) (string, error) + func GenVolumeMounts(volumeFlag []string) (map[string]spec.Mount, map[string]*NamedVolume, map[string]*OverlayVolume, ...) + func SetupUserNS(idmappings *storage.IDMappingOptions, userns Namespace, g *generate.Generator) (string, error) + func SplitVolumeString(vol string) []string + type ContainerBasicConfig struct + Annotations map[string]string + Command []string + ConmonPidFile string + ContainerCreateCommand []string + DependencyContainers []string + Entrypoint []string + Env map[string]string + EnvHost bool + EnvSecrets map[string]string + HTTPProxy bool + HostUsers []string + Hostname string + InitContainerType string + Labels map[string]string + LogConfiguration *LogConfig + Name string + Namespace string + OCIRuntime string + Passwd *bool + PasswdEntry string + Personality *spec.LinuxPersonality + PidFile string + PidNS Namespace + Pod string + PreserveFDs uint + RawImageName string + Remove bool + RestartPolicy string + RestartRetries *uint + SdNotifyMode string + Stdin bool + StopSignal *syscall.Signal + StopTimeout *uint + Sysctl map[string]string + Systemd string + Terminal bool + Timeout uint + Timezone string + UnsetEnv []string + UnsetEnvAll bool + UtsNS Namespace + type ContainerCgroupConfig struct + CgroupNS Namespace + CgroupParent string + CgroupsMode string + type ContainerHealthCheckConfig struct + HealthConfig *manifest.Schema2HealthConfig + type ContainerNetworkConfig struct + CNINetworks []string + DNSOptions []string + DNSSearch []string + DNSServers []net.IP + Expose map[uint16]string + HostAdd []string + NetNS Namespace + NetworkOptions map[string][]string + Networks map[string]nettypes.PerNetworkOptions + PortMappings []nettypes.PortMapping + PublishExposedPorts bool + UseImageHosts bool + UseImageResolvConf bool + type ContainerResourceConfig struct + CPUPeriod uint64 + CPUQuota int64 + CgroupConf map[string]string + OOMScoreAdj *int + ResourceLimits *spec.LinuxResources + Rlimits []spec.POSIXRlimit + ThrottleReadBpsDevice map[string]spec.LinuxThrottleDevice + ThrottleReadIOPSDevice map[string]spec.LinuxThrottleDevice + ThrottleWriteBpsDevice map[string]spec.LinuxThrottleDevice + ThrottleWriteIOPSDevice map[string]spec.LinuxThrottleDevice + WeightDevice map[string]spec.LinuxWeightDevice + type ContainerSecurityConfig struct + ApparmorProfile string + CapAdd []string + CapDrop []string + Groups []string + IDMappings *types.IDMappingOptions + Mask []string + NoNewPrivileges bool + Privileged bool + ProcOpts []string + ReadOnlyFilesystem bool + SeccompPolicy string + SeccompProfilePath string + SelinuxOpts []string + Umask string + Unmask []string + User string + UserNS Namespace + type ContainerStorageConfig struct + ChrootDirs []string + CreateWorkingDir bool + DeviceCgroupRule []spec.LinuxDeviceCgroup + Devices []spec.LinuxDevice + DevicesFrom []string + HostDeviceList []spec.LinuxDevice + Image string + ImageVolumeMode string + ImageVolumes []*ImageVolume + Init bool + InitPath string + IpcNS Namespace + Mounts []spec.Mount + OverlayVolumes []*OverlayVolume + Rootfs string + RootfsOverlay bool + RootfsPropagation string + Secrets []Secret + ShmSize *int64 + StorageOpts map[string]string + Volatile bool + Volumes []*NamedVolume + VolumesFrom []string + WorkDir string + type ImageVolume struct + Destination string + ReadWrite bool + Source string + type LogConfig struct + Driver string + Options map[string]string + Path string + Size int64 + type NamedVolume struct + Dest string + Name string + Options []string + type Namespace struct + NSMode NamespaceMode + Value string + func ParseCgroupNamespace(ns string) (Namespace, error) + func ParseIPCNamespace(ns string) (Namespace, error) + func ParseNamespace(ns string) (Namespace, error) + func ParseNetworkFlag(networks []string) (Namespace, map[string]types.PerNetworkOptions, map[string][]string, error) + func ParseUserNamespace(ns string) (Namespace, error) + func (n *Namespace) IsAuto() bool + func (n *Namespace) IsBridge() bool + func (n *Namespace) IsContainer() bool + func (n *Namespace) IsDefault() bool + func (n *Namespace) IsHost() bool + func (n *Namespace) IsKeepID() bool + func (n *Namespace) IsNoMap() bool + func (n *Namespace) IsNone() bool + func (n *Namespace) IsPath() bool + func (n *Namespace) IsPod() bool + func (n *Namespace) IsPrivate() bool + func (n *Namespace) String() string + type NamespaceMode string + const Auto + const Bridge + const Default + const DefaultKernelNamespaces + const FromContainer + const FromPod + const Host + const KeepID + const NoMap + const NoNetwork + const None + const Path + const Private + const Shareable + const Slirp + type OverlayVolume struct + Destination string + Options []string + Source string + type PodBasicConfig struct + Devices []string + ExitPolicy string + Hostname string + InfraCommand []string + InfraConmonPidFile string + InfraImage string + InfraName string + Labels map[string]string + Name string + NoInfra bool + Pid Namespace + PodCreateCommand []string + ShareParent *bool + SharedNamespaces []string + Sysctl map[string]string + Userns Namespace + type PodCgroupConfig struct + CgroupParent string + type PodNetworkConfig struct + CNINetworks []string + DNSOption []string + DNSSearch []string + DNSServer []net.IP + HostAdd []string + NetNS Namespace + NetworkOptions map[string][]string + Networks map[string]types.PerNetworkOptions + NoManageHosts bool + NoManageResolvConf bool + PortMappings []types.PortMapping + type PodResourceConfig struct + CPUPeriod uint64 + CPUQuota int64 + ResourceLimits *spec.LinuxResources + ThrottleReadBpsDevice map[string]spec.LinuxThrottleDevice + type PodSecurityConfig struct + IDMappings *storageTypes.IDMappingOptions + SecurityOpt []string + type PodSpecGenerator struct + InfraContainerSpec *SpecGenerator + ServiceContainerID string + func NewPodSpecGenerator() *PodSpecGenerator + func (p *PodSpecGenerator) Validate() error + type PodStorageConfig struct + ImageVolumes []*ImageVolume + Mounts []spec.Mount + OverlayVolumes []*OverlayVolume + Volumes []*NamedVolume + VolumesFrom []string + type Secret struct + GID uint32 + Mode uint32 + Source string + Target string + UID uint32 + type SpecGenerator struct + func NewSpecGenerator(arg string, rootfs bool) *SpecGenerator + func NewSpecGeneratorWithRootfs(rootfs string) *SpecGenerator + func (s *SpecGenerator) GetImage() (*libimage.Image, string) + func (s *SpecGenerator) SetImage(image *libimage.Image, resolvedImageName string) + func (s *SpecGenerator) Validate() error