Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Feb 20, 2022. It is now read-only.

Added docker container State.Health.Status as a metric #7 #11

Open
Cobertos wants to merge 3 commits into prometheus-net:master
base: master
Choose a base branch
Loading
from Cobertos:master

Conversation

Copy link

@Cobertos Cobertos commented Aug 28, 2020
edited
Loading

Fixes #7

geekdave, Aritain, MaxWebZ, zkhcohen, melhesedek, and linuxhuskarl reacted with thumbs up emoji
Copy link
Author

Cobertos commented Aug 28, 2020
edited
Loading

So the final implementation for the gauge is as follows:

  • Healthy = 1
  • Starting = 0.5
  • Unhealthy = 0
  • No health information, we never publish the gauge, and unpublish if it was previously published, but I don't know if that's even possible.

Here's the output. In this case, practical_merkle is a container meant to always be unhealthy, HEALTHCHECK CMD exit 1

image

Copy link
Author

Any chance this can get merged @sandersaares ?

franz-josef-kaiser, Aritain, melhesedek, norcorider, MaxWebZ, hr6134, brs-lphv, linuxhuskarl, and artem30801 reacted with thumbs up emoji

Copy link
Author

Cobertos commented Feb 8, 2021

If anyone is looking to use this today, you can always use a git submodule.

git submodule add https://github.com/Cobertos/docker_exporter

Then in your docker-compose.yml

 prometheus-docker-exporter:
 build: 
 context: docker_exporter/
 restart: always
 container_name: prometheus-docker-exporter
 volumes:
 - /var/run/docker.sock:/var/run/docker.sock:ro

Copy link

Why hasn't this been merged yet. Really disappointing that no one has taken the time to review it... this is basic functionality.

mr-simonski, melhesedek, and linuxhuskarl reacted with thumbs up emoji

Copy link

@sandersaares I would need this as well. Our images might not start due to unforeseen situations during boot of our APIs. Docker marks them as running while our healthchecks indicate the truth, that they are starting for ages. Would be very helpful to have this merged.

zkhcohen, melhesedek, dr4hcu5-jan, and linuxhuskarl reacted with thumbs up emoji

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

docker container healthy

AltStyle によって変換されたページ (->オリジナル) /