How to find the status of a container using prometheus?

Viewed 642

enter image description here

I want to get status of a container using cadvisor and prometheus. I know that I can get the created time using

time() - container_start_time_seconds{name="container_name"} 

Is there any method to find the status of a container?

1 Answers

You can just do up on PromQL

1 means up, and 0 means down.

image demo

Related