Skip to content

fix: add healthcheck to MongoDB service in docker-compose#17

Merged
Kmario19 merged 1 commit intomainfrom
fix/mongodb-healthcheck
Apr 4, 2025
Merged

fix: add healthcheck to MongoDB service in docker-compose#17
Kmario19 merged 1 commit intomainfrom
fix/mongodb-healthcheck

Conversation

@Kmario19
Copy link
Owner

@Kmario19 Kmario19 commented Apr 4, 2025

This pull request includes an important change to the docker-compose.yml file to improve the reliability and monitoring of the MongoDB service. The most significant change is the addition of a health check configuration for the MongoDB service.

Improvements to MongoDB service:

  • docker-compose.yml: Added a health check configuration to ensure MongoDB is running and responsive. This includes a command to ping the database, with specified intervals, timeouts, retries, and start period.

Copilot AI review requested due to automatic review settings April 4, 2025 03:13
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 1 out of 1 changed files in this pull request and generated no comments.

Comments suppressed due to low confidence (1)

docker-compose.yml:14

  • Ensure that the MongoDB container image includes the 'mongosh' shell. If it only provides the 'mongo' shell, update the command accordingly to avoid a failing health check.
test: ["CMD", "mongosh", "--eval", "db.adminCommand('ping')", "--quiet"]

@Kmario19 Kmario19 merged commit 2630311 into main Apr 4, 2025
1 check passed
@Kmario19 Kmario19 deleted the fix/mongodb-healthcheck branch April 4, 2025 03:13
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.

2 participants