Can anyone help me understand better liveness and readiness probes?
From my understanding they complement each other, readiness probes help ensure that requests aren’t sent to unavailable containers but can’t restart them. Whereas liveness probes can’t stop requests but can restart the container after the timeout period.
Typically would both liveness probes and readiness probes check the same thing i.e. httpGet or exec command?
You want to use liveness to check if the container need to be restart/replace or not.
Readiness doesn’t participate in container lifecycle, it only indicate that the application is ready to receive the request or not.
• liveness = false, the container will be killed by kubelet.
• readiness = false => just do not route traffic to this.
You could see liveness like a constant healthcheck from your container and readiness like a test to see if it’s ready for receive traffic. You can test to see if your container is connecting with a database for example.
Thanks both for the clarification. :skin-tone-2: