Skip to content

Conversation

prigornitskiy
Copy link
Contributor

Add curl to image for health checks

@cshum
Copy link
Owner

cshum commented May 29, 2025

Adding curl for a healthcheck in the Docker Compose configuration is unnecessary in this case.

The service is already managed by Docker, which handles the container lifecycle and will automatically restart the service if it fails. The curl healthcheck doesn't provide additional meaningful context—if the service is down, Docker will take action regardless.

@cshum cshum closed this May 29, 2025
@prigornitskiy
Copy link
Contributor Author

Sometimes service stop respond without any reason by http. I talk about v1.4.17.

@adechassey
Copy link

adechassey commented Jun 14, 2025

Adding curl for a healthcheck in the Docker Compose configuration is unnecessary in this case.

The service is already managed by Docker, which handles the container lifecycle and will automatically restart the service if it fails. The curl healthcheck doesn't provide additional meaningful context—if the service is down, Docker will take action regardless.

Hey Adrian,
Thanks for this amazing lib.
I do not totally agree here as having a proper healthcheck would allow to mark the docker service as "healthy" and listen for this event from other services (e.g. : make sure service A started successfully before starting service B).
Would you reconsider adding curl ?
Cheers,
Antoine

@cshum
Copy link
Owner

cshum commented Jun 15, 2025

Hi @prigornitskiy @adechassey, lets add the curl into the Dockerfile as it would come handy.
But imo no need adding it for a simple docker compose example.

@cshum cshum reopened this Jun 15, 2025
@prigornitskiy
Copy link
Contributor Author

@cshum ready!

@cshum cshum merged commit c382c6b into cshum:master Jun 18, 2025
2 checks passed
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

Successfully merging this pull request may close these issues.

3 participants