5.26 Check container health at runtime

Information

If the container image does not have an HEALTHCHECK instruction defined, use --health-
cmd parameter at container runtime for checking container health.One of the important security triads is availability. If the container image you are using
does not have a pre-defined HEALTHCHECK instruction, use the --health-cmd parameter to
check container health at runtime.Based on the reported health status, you could take necessary actions.

Solution

Run the container using --health-cmd and the other parameters.For example,docker run -d --health-cmd='stat /etc/passwd || exit 1' nginxImpact-None.Default Value-By default, health checks are not done at container runtime.

See Also

https://workbench.cisecurity.org/files/517

Item Details

Category: CONFIGURATION MANAGEMENT

References: 800-53|CM-6b.

Plugin: Unix

Control ID: de805594d5a5a3bd8a23571e027ace67bf105584071bf925f3e3bb40b826d03b