Documentation ¶
Index ¶
- func CheckCustomResourceDefinition(crd *apiextensionsv1.CustomResourceDefinition) error
- func CheckDaemonSet(daemonSet *appsv1.DaemonSet) error
- func CheckDeployment(deployment *appsv1.Deployment) error
- func CheckJob(job *batchv1.Job) error
- func CheckManagedResource(mr *v1alpha1.ManagedResource) error
- func CheckManagedResourceApplied(mr *v1alpha1.ManagedResource) error
- func CheckManagedResourceHealthy(mr *v1alpha1.ManagedResource) error
- func CheckPod(pod *corev1.Pod) error
- func CheckReplicaSet(rs *appsv1.ReplicaSet) error
- func CheckReplicationController(rc *corev1.ReplicationController) error
- func CheckService(ctx context.Context, scheme *runtime.Scheme, c client.Client, ...) error
- func CheckStatefulSet(statefulSet *appsv1.StatefulSet) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckCustomResourceDefinition ¶
func CheckCustomResourceDefinition(crd *apiextensionsv1.CustomResourceDefinition) error
CheckCustomResourceDefinition checks whether the given CustomResourceDefinition is healthy. A CRD is considered healthy if its `NamesAccepted` and `Established` conditions are with status `True` and its `Terminating` condition is missing or has status `False`.
func CheckDaemonSet ¶ added in v0.9.0
CheckDaemonSet checks whether the given DaemonSet is healthy. A DaemonSet is considered healthy if its controller observed its current revision and if its desired number of scheduled pods is equal to its updated number of scheduled pods.
func CheckDeployment ¶ added in v0.9.0
func CheckDeployment(deployment *appsv1.Deployment) error
CheckDeployment checks whether the given Deployment is healthy. A deployment is considered healthy if the controller observed its current revision and if the number of updated replicas is equal to the number of replicas.
func CheckJob ¶
CheckJob checks whether the given Job is healthy. A Job is considered healthy if its `JobFailed` condition is missing or has status `False`.
func CheckManagedResource ¶
func CheckManagedResource(mr *v1alpha1.ManagedResource) error
CheckManagedResource checks if all conditions of a ManagedResource ('ResourcesApplied' and 'ResourcesHealthy') are True and .status.observedGeneration matches the current .metadata.generation
func CheckManagedResourceApplied ¶ added in v0.10.0
func CheckManagedResourceApplied(mr *v1alpha1.ManagedResource) error
CheckManagedResourceApplied checks if the condition 'ResourcesApplied' of a ManagedResource is True and the .status.observedGeneration matches the current .metadata.generation
func CheckManagedResourceHealthy ¶ added in v0.10.0
func CheckManagedResourceHealthy(mr *v1alpha1.ManagedResource) error
CheckManagedResourceHealthy checks if the condition 'ResourcesHealthy' of a ManagedResource is True
func CheckPod ¶
CheckPod checks whether the given Pod is healthy. A Pod is considered healthy if its `.status.phase` is `Running` or `Succeeded`.
func CheckReplicaSet ¶
func CheckReplicaSet(rs *appsv1.ReplicaSet) error
CheckReplicaSet checks whether the given ReplicaSet is healthy. A ReplicaSet is considered healthy if the controller observed its current revision and if the number of ready replicas is equal to the number of replicas.
func CheckReplicationController ¶
func CheckReplicationController(rc *corev1.ReplicationController) error
CheckReplicationController checks whether the given ReplicationController is healthy. A ReplicationController is considered healthy if the controller observed its current revision and if the number of ready replicas is equal to the number of replicas.
func CheckService ¶ added in v0.22.0
func CheckService(ctx context.Context, scheme *runtime.Scheme, c client.Client, service *corev1.Service) error
CheckService checks whether the given service is healthy. A Service is considered unhealthy if it is of type `LoadBalancer` but doesn't have an ingress element in its status.
func CheckStatefulSet ¶ added in v0.9.0
func CheckStatefulSet(statefulSet *appsv1.StatefulSet) error
CheckStatefulSet checks whether the given StatefulSet is healthy. A StatefulSet is considered healthy if its controller observed its current revision, it is not in an update (i.e. UpdateRevision is empty) and if its current replicas are equal to its desired replicas.
Types ¶
This section is empty.