Documentation ¶
Index ¶
- func AppendEnvVarIfNotExists(slice []v1.EnvVar, elems ...v1.EnvVar) []v1.EnvVar
- func AppendVolumeIfNotExists(slice []v1.Volume, volume v1.Volume) []v1.Volume
- func Bool(b bool) *bool
- func Filter(origin map[string]string, predicate func(string) bool) map[string]string
- func FirstNonNilError(objects []error) error
- func Includes(slice []string, value string) bool
- func IncludesArg(slice []string, arg string) bool
- func IsGPUEnabled(requirements v1.ResourceRequirements) bool
- func IsPrefixSupported(input string, prefixes []string) bool
- func MergeEnvs(baseEnvs []v1.EnvVar, overrideEnvs []v1.EnvVar) []v1.EnvVar
- func RemoveString(slice []string, s string) (result []string)
- func UInt64(u uint64) *uint64
- func Union(maps ...map[string]string) map[string]string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AppendEnvVarIfNotExists ¶ added in v0.10.0
func AppendVolumeIfNotExists ¶ added in v0.7.0
func FirstNonNilError ¶ added in v0.7.0
FirstNonNilError returns the first non nil interface in the slice
func IncludesArg ¶ added in v0.7.0
func IsGPUEnabled ¶ added in v0.7.0
func IsGPUEnabled(requirements v1.ResourceRequirements) bool
func IsPrefixSupported ¶ added in v0.8.0
IsPrefixSupported Check if a given string contains one of the prefixes in the provided list.
func MergeEnvs ¶ added in v0.10.0
MergeEnvs Merge a slice of EnvVars (`O`) into another slice of EnvVars (`B`), which does the following: 1. If an EnvVar is present in B but not in O, value remains unchanged in the result 2. If an EnvVar is present in `O` but not in `B`, appends to the result 3. If an EnvVar is present in both O and B, uses the value from O in the result
func RemoveString ¶ added in v0.7.0
RemoveString Helper functions to remove string from a slice of strings.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.