Description
Enhance Liberty Operator's support for probes by allowing users to easily configure file-based liveness/readiness/startup probes with the exec
command option.
For the default probes configured by Liberty Operator, we should consider adding a toggle to switch between httpGet
and file-based exec
probes. Users should be able to easily override some/subset of the defaults.
At the moment, the exec
field under probes is intentionally hidden in the OpenShift UI, to simplify (as the majority use httpGet). Revisit this and consider exposing some/subset of fields as part of this file-based probes support.
The timeoutSeconds
of the probe (in particular for startup) might be used to continuously recheck the file (as opposed to checking once and exiting) to allow faster startup/probe evaluation. See the Liberty epic linked below for more information. If the timeout is passed as env/variable to the exec script, then the Liberty Operator should set that value.
Documentation:
In some systems (i.e. EASeJ) , executing commands in Pods would be blocked by cluster policy. Document the ability to execute commands as a prereq to using file-based probes.
Other considerations:
- Additional RBAC permissions should not be needed as the application, not Liberty Operator, would perform the execution
- Validate the user-provided command if it's possible/makes sense
Related feature in Liberty runtime: OpenLiberty/open-liberty#30056