Documentation ¶
Index ¶
- func ParseAnnotation(annotations []string) (map[string]string, error)
- func ParseDeviceMappings(devices []string) ([]*types.DeviceMapping, error)
- func ParseDiskQuota(quotas []string) (map[string]string, error)
- func ParseExposedPorts(portList, expose []string) (map[string]interface{}, error)
- func ParseIntelRdt(intelRdtL3Cbm string) (string, error)
- func ParseLabels(labels []string) (map[string]string, error)
- func ParseMemory(memory string) (int64, error)
- func ParseMemorySwap(memorySwap string) (int64, error)
- func ParseNetworks(networks []string) (*types.NetworkingConfig, string, error)
- func ParsePortBinding(ports []string) (types.PortMap, error)
- func ParseRestartPolicy(restartPolicy string) (*types.RestartPolicy, error)
- func ParseSysctls(sysctls []string) (map[string]string, error)
- func ValidateAnnotation(annotations map[string]string) error
- func ValidateCPUPeriod(period int64) error
- func ValidateCPUQuota(quota int64) error
- func ValidateDeviceMode(mode string) bool
- func ValidateDiskQuota(quotaMaps map[string]string) error
- func ValidateExposedPorts(ports map[string]interface{}) error
- func ValidateLabels(map[string]string) error
- func ValidateMemorySwap(memorySwap int64) error
- func ValidateMemorySwappiness(memorySwappiness int64) error
- func ValidateNetworks(nwConfig *types.NetworkingConfig) error
- func ValidateOOMScore(score int64) error
- func ValidatePortBinding(portBindings types.PortMap) error
- func ValidateRestartPolicy(policy *types.RestartPolicy) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ParseAnnotation ¶
ParseAnnotation parses runtime annotations format.
func ParseDeviceMappings ¶
func ParseDeviceMappings(devices []string) ([]*types.DeviceMapping, error)
ParseDeviceMappings parse devicemappings
func ParseDiskQuota ¶
ParseDiskQuota parses diskquota configurations of container.
func ParseExposedPorts ¶
ParseExposedPorts parse ports. FIXME(ziren): add more explanation
func ParseIntelRdt ¶
ParseIntelRdt parses inter-rdt params of container
func ParseLabels ¶
ParseLabels parses the labels params of container.
func ParseMemory ¶
ParseMemory parses the memory param of container.
func ParseMemorySwap ¶
ParseMemorySwap parses the memory-swap param of container.
func ParseNetworks ¶
func ParseNetworks(networks []string) (*types.NetworkingConfig, string, error)
ParseNetworks parses network configurations of container.
func ParsePortBinding ¶
ParsePortBinding parse string list to PortMap FIXME(ziren): add examples
func ParseRestartPolicy ¶
func ParseRestartPolicy(restartPolicy string) (*types.RestartPolicy, error)
ParseRestartPolicy parses restart policy param of container.
func ParseSysctls ¶
ParseSysctls parses the sysctl params of container
func ValidateAnnotation ¶
ValidateAnnotation validate the correctness of spec annotation param of a container.
func ValidateCPUPeriod ¶
ValidateCPUPeriod validates CPU options for container.
func ValidateCPUQuota ¶
ValidateCPUQuota validates CPU options for container.
func ValidateDeviceMode ¶
ValidateDeviceMode checks if the mode for device is valid or not. valid mode is a composition of r (read), w (write), and m (mknod).
func ValidateDiskQuota ¶
ValidateDiskQuota verifies diskquota configurations of container.
func ValidateExposedPorts ¶
ValidateExposedPorts verify the correction of exposed ports.
func ValidateLabels ¶
ValidateLabels verifies the correct of labels
func ValidateMemorySwap ¶
ValidateMemorySwap verifies the correctness of memory-swap.
func ValidateMemorySwappiness ¶
ValidateMemorySwappiness verifies the correctness of memory-swappiness.
func ValidateNetworks ¶
func ValidateNetworks(nwConfig *types.NetworkingConfig) error
ValidateNetworks verifies network configurations of container.
func ValidateOOMScore ¶
ValidateOOMScore validates oom score
func ValidatePortBinding ¶
ValidatePortBinding verify PortMap struct correctness.
func ValidateRestartPolicy ¶
func ValidateRestartPolicy(policy *types.RestartPolicy) error
ValidateRestartPolicy verifies the correctness of restart policy of container.
Types ¶
This section is empty.