feat: add a metric representing a container's health
fpoirotte opened this issue · comments
Is your feature request related to a problem? Please describe.
I would like to be able to query a container's health in addition to its state.
Describe the solution you'd like
I propose to add a new gauge metric named podman_container_health
. The metric would map the values defined in podman/libpod/define/healthchecks.go (healthy, unhealthy & starting) to integers and the help message would help map those values back to their intended meaning (similar to the way podman_container_state
is defined).
Additional context
n/a
A friendly reminder that this issue had no activity for 30 days.
@mheon Don't we already have this?
We do, exposed via both podman ps
and podman inspect
(both API and CLI).
I've prepared a working implementation based on the one for podman_container_state
.
I'll try to get it greenlit by my employer tomorrow and to upload a PR as a result.