Documentation ¶
Index ¶
- Constants
- func Annotations(spec v1.SpecInterface) map[string]string
- func ContainerArgs(spec v1.SpecInterface) []string
- func ContainerCommand(spec v1.SpecInterface) []string
- func ContainerSecurityContext(spec v1.SpecInterface) *corev1.SecurityContext
- func Count(podList v1.PodList) (creating, ready, failed []string)
- func Envs(spec v1.SpecInterface, config map[string]interface{}, ...) []corev1.EnvVar
- func Labels(clusterName string, spec v1.SpecInterface) map[string]string
- func LifeCycle(lifeCycle *corev1.Lifecycle, preStopScriptPath string) *corev1.Lifecycle
- func LivenessProbe(livenessProbeFailureSeconds *int32, port int32, path string) *corev1.Probe
- func MountConfigMapInfo(volumes []corev1.Volume, volumeMounts []corev1.VolumeMount, ...) ([]corev1.Volume, []corev1.VolumeMount)
- func MountConfigMaps(spec v1.SpecInterface, volumes []corev1.Volume, ...) ([]corev1.Volume, []corev1.VolumeMount)
- func MountEmptyDirVolume(volumes []corev1.Volume, volumeMounts []corev1.VolumeMount, ...) ([]corev1.Volume, []corev1.VolumeMount)
- func MountHostPathVolume(volumes []corev1.Volume, volumeMounts []corev1.VolumeMount, volumeName string, ...) ([]corev1.Volume, []corev1.VolumeMount)
- func MountPersistentVolumeClaim(volumes []corev1.Volume, volumeMounts []corev1.VolumeMount, ...) ([]corev1.Volume, []corev1.VolumeMount)
- func MountSecrets(volumes []corev1.Volume, volumeMounts []corev1.VolumeMount, ...) ([]corev1.Volume, []corev1.VolumeMount)
- func MountStorageVolumes(spec v1.SpecInterface) ([]corev1.Volume, []corev1.VolumeMount)
- func PodSecurityContext(spec v1.SpecInterface) *corev1.PodSecurityContext
- func Ports(spec v1.SpecInterface, config map[string]interface{}) []corev1.ContainerPort
- func ReadinessProbe(readinessProbeFailureSeconds *int32, port int32, path string) *corev1.Probe
- func Spec(spec v1.SpecInterface, container corev1.Container, volumes []corev1.Volume) corev1.PodSpec
- func SpecialStorageClassName(sv v1.StorageVolume) string
- func StartupProbe(startupProbeFailureSeconds *int32, port int32, path string) *corev1.Probe
- func Status(podList v1.PodList) map[string]PodStatus
- type PodStatus
Constants ¶
View Source
const (
HEALTH_API_PATH = "/api/health"
)
Variables ¶
This section is empty.
Functions ¶
func Annotations ¶
func Annotations(spec v1.SpecInterface) map[string]string
func ContainerArgs ¶ added in v1.9.6
func ContainerArgs(spec v1.SpecInterface) []string
func ContainerCommand ¶ added in v1.9.6
func ContainerCommand(spec v1.SpecInterface) []string
func ContainerSecurityContext ¶ added in v1.7.1
func ContainerSecurityContext(spec v1.SpecInterface) *corev1.SecurityContext
func LivenessProbe ¶
LivenessProbe returns a liveness probe.
func MountConfigMapInfo ¶
func MountConfigMapInfo(volumes []corev1.Volume, volumeMounts []corev1.VolumeMount, cmInfo v1.ConfigMapInfo, mountPath string) ([]corev1.Volume, []corev1.VolumeMount)
MountConfigMapInfo parse ConfigMapInfo from spec and mount them to pod. Note: we can not reuse MountConfigMaps because it generates a volume name by call getVolumeName,
func MountConfigMaps ¶
func MountConfigMaps(spec v1.SpecInterface, volumes []corev1.Volume, volumeMounts []corev1.VolumeMount, references []v1.ConfigMapReference) ([]corev1.Volume, []corev1.VolumeMount)
func MountEmptyDirVolume ¶ added in v1.9.0
func MountEmptyDirVolume(volumes []corev1.Volume, volumeMounts []corev1.VolumeMount, volumeName, mountPath, subPath string) ([]corev1.Volume, []corev1.VolumeMount)
func MountHostPathVolume ¶ added in v1.9.3
func MountHostPathVolume(volumes []corev1.Volume, volumeMounts []corev1.VolumeMount, volumeName string, mountPath string, subPath string, hostPath *corev1.HostPathVolumeSource) ([]corev1.Volume, []corev1.VolumeMount)
func MountPersistentVolumeClaim ¶ added in v1.9.0
func MountPersistentVolumeClaim(volumes []corev1.Volume, volumeMounts []corev1.VolumeMount, volumeName, mountPath, subPath string) ([]corev1.Volume, []corev1.VolumeMount)
func MountSecrets ¶
func MountSecrets(volumes []corev1.Volume, volumeMounts []corev1.VolumeMount, references []v1.SecretReference) ([]corev1.Volume, []corev1.VolumeMount)
func MountStorageVolumes ¶
func MountStorageVolumes(spec v1.SpecInterface) ([]corev1.Volume, []corev1.VolumeMount)
MountStorageVolumes parse StorageVolumes from spec and mount them to pod. If StorageClassName is EmptyDir, mount an emptyDir volume to pod.
func PodSecurityContext ¶ added in v1.7.1
func PodSecurityContext(spec v1.SpecInterface) *corev1.PodSecurityContext
func Ports ¶
func Ports(spec v1.SpecInterface, config map[string]interface{}) []corev1.ContainerPort
func ReadinessProbe ¶
ReadinessProbe returns a readiness probe.
func SpecialStorageClassName ¶ added in v1.9.7
func SpecialStorageClassName(sv v1.StorageVolume) string
SpecialStorageClassName returns the special storage class name of the storage volume, else return "". Now we support HostPath and EmptyDir as special storage class.
func StartupProbe ¶
StartupProbe returns a startup probe.
Types ¶
Click to show internal directories.
Click to hide internal directories.