Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Healthcheck inclusion #24

Open
ThomDietrich opened this issue Aug 10, 2020 · 2 comments
Open

Healthcheck inclusion #24

ThomDietrich opened this issue Aug 10, 2020 · 2 comments

Comments

@ThomDietrich
Copy link

Hello all,

This is a copy of bcardiff#14 - not sure which issue tracker is better suited but I am currently using the pfidr34 fork.

(reference: https://docs.docker.com/engine/reference/builder/#healthcheck)

I wanted to raise a discussion to define a healthcheck for this image, either in the image itself or as a post-defined instruction for run / docker-compose.

Side not on the existing healthcheck.io integration: Imho these two can be implemented in parallel.

Which command do you think is best suited to check the health of the image? It would be easy to check that cron is running but a better health indicator would check the success of actual cron jobs.

Any suggestions? What works for you? Are you interested to implement something in the code of this image?

Best!

@pfidr34
Copy link
Owner

pfidr34 commented Feb 11, 2021

@ThomDietrich

Just wanted to give you an update that I have read this issue and I think it is a good idea.

I am currently very busy at work and have not had time to look into this but may in the future.

If you would like to submit a pull request for this feature I would also be happy to review that.

@dantebarba
Copy link
Collaborator

As a sidenote this could be done by:

  1. saving the last n status codes of the rclone command into a file
  2. point the healthcheck to read this file. If the status code failed the last n-times, mark as unhealthy
  3. the file should be created in the Dockerfile and by default should contain the first 0, so Docker assumes healthy on startup.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants