C-0056 - Configured liveness probe
Configured liveness probe
Framework
DevOpsBest, YAML-scanning, AllControls
Severity
Low
Description of the the issue
Liveness probe is intended to ensure that workload remains healthy during its entire execution lifecycle, or otherwise restrat the container. It is highly recommended to define liveness probe for every worker container. This control finds all the PODs where the Liveness probe is not configured.
Related resources
DaemonSet, Deployment, Pod, ReplicaSet, StatefulSet
What does this control test
Liveness probe is intended to ensure that workload remains healthy during its entire execution lifecycle, or otherwise restrat the container. It is highly recommended to define liveness probe for every worker container. This control finds all the PODs where the Liveness probe is not configured.
Remediation
Ensure Liveness probes are configured wherever possible.
Example
livenessProbe: # we are looking for this section in the resource definition
exec:
command:
- cat
- /tmp/healthy
initialDelaySeconds: 5
periodSeconds: 5
Updated about 2 months ago