Documentation ¶
Overview ¶
Package k8sutil for Kubernetes helpers.
Package k8sutil for Kubernetes helpers.
Package k8sutil for Kubernetes helpers.
Package k8sutil for Kubernetes helpers.
Index ¶
- Constants
- func ConfigDirEnvVar() v1.EnvVar
- func ConfigOverrideEnvVar() v1.EnvVar
- func ConfigOverrideMount() v1.VolumeMount
- func ConfigOverrideVolume() v1.Volume
- func MakeRookImage(version string) string
- func NamespaceEnvVar() v1.EnvVar
- func PathToVolumeName(path string) string
- func PodIPEnvVar(property string) v1.EnvVar
- func RepoPrefixEnvVar() v1.EnvVar
- func SetPodVersion(pod *v1.Pod, key, version string)
- type Placement
Constants ¶
View Source
const ( // V1Alpha1 version for kubernetes resources V1Alpha1 = "v1alpha1" // V1Beta1 version for kubernetes resources V1Beta1 = "v1beta1" // V1 version for kubernetes resources V1 = "v1" )
View Source
const ( // Namespace for rook Namespace = "rook" // CustomResourceGroup for rook CRD CustomResourceGroup = "rook.io" // DefaultNamespace for the cluster DefaultNamespace = "default" // DataDirVolume data dir volume DataDirVolume = "rook-data" // DataDir folder DataDir = "/var/lib/rook" // RookType for the CRD RookType = "kubernetes.io/rook" // RbdType for the RBD mounts RbdType = "kubernetes.io/rbd" )
View Source
const ( // AppAttr app label AppAttr = "app" // ClusterAttr cluster label ClusterAttr = "rook_cluster" // VersionAttr version label VersionAttr = "rook_version" // PublicIPEnvVar public IP env var PublicIPEnvVar = "ROOK_PUBLIC_IPV4" // PrivateIPEnvVar pod IP env var PrivateIPEnvVar = "ROOK_PRIVATE_IPV4" // DefaultRepoPrefix repo prefix DefaultRepoPrefix = "rook" // ConfigOverrideName config override name ConfigOverrideName = "rook-config-override" // ConfigOverrideVal config override value ConfigOverrideVal = "config" )
Variables ¶
This section is empty.
Functions ¶
func ConfigDirEnvVar ¶ added in v0.4.0
ConfigDirEnvVar config dir env var
func ConfigOverrideEnvVar ¶ added in v0.5.0
ConfigOverrideEnvVar config override env var
func ConfigOverrideMount ¶ added in v0.5.0
func ConfigOverrideMount() v1.VolumeMount
ConfigOverrideMount is an override mount
func ConfigOverrideVolume ¶ added in v0.5.0
ConfigOverrideVolume is an override volume
func MakeRookImage ¶
MakeRookImage formats the container name
func PathToVolumeName ¶ added in v0.4.0
PathToVolumeName converts a path to a valid volume name
func RepoPrefixEnvVar ¶ added in v0.4.0
RepoPrefixEnvVar repo prefix env var
func SetPodVersion ¶
SetPodVersion sets the pod annotation
Types ¶
type Placement ¶ added in v0.5.0
type Placement struct { NodeAffinity *v1.NodeAffinity `json:"nodeAffinity,omitempty"` Tolerations []v1.Toleration `json:"tolerations,omitemtpy"` }
Placement encapsulates the various kubernetes options that control where pods are scheduled and executed.
func (Placement) ApplyToPodSpec ¶ added in v0.5.0
ApplyToPodSpec adds placement to a pod spec
Click to show internal directories.
Click to hide internal directories.