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

Add docker healthcheck #3203

Merged
merged 2 commits into from
Oct 12, 2024
Merged

Add docker healthcheck #3203

merged 2 commits into from
Oct 12, 2024

Conversation

haarg
Copy link
Member

@haarg haarg commented Oct 10, 2024

Adds a healthcheck end point doing some rudimentary work that can be checked.

Adds health checks to the docker containers. These will be used by docker-compose. Kubernetes doesn't use the declared docker health checks, so it won't have any impact on production.

Copy link

codecov bot commented Oct 10, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 73.08%. Comparing base (ffbab6c) to head (b7b7d10).
Report is 5 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3203      +/-   ##
==========================================
+ Coverage   72.95%   73.08%   +0.12%     
==========================================
  Files          69       69              
  Lines        2392     2396       +4     
  Branches      338      338              
==========================================
+ Hits         1745     1751       +6     
+ Misses        519      517       -2     
  Partials      128      128              
Files with missing lines Coverage Δ
lib/MetaCPAN/Web/Controller/Root.pm 75.47% <100.00%> (+2.00%) ⬆️

... and 1 file with indirect coverage changes

@haarg haarg force-pushed the haarg/healthcheck branch from 6351db8 to 6f82ad2 Compare October 10, 2024 23:30
haarg added 2 commits October 11, 2024 01:33
Add a /healthcheck end point, returning a simple JSON structure. Use a
template rather than normal JSON encoding to ensure that the template
engine is working correctly.

In the future, this could be extended to check that the API is
available, but for now a simple check that just the web server is
running is good enough.
@haarg haarg force-pushed the haarg/healthcheck branch from 6f82ad2 to b7b7d10 Compare October 10, 2024 23:34
@haarg haarg merged commit 5f2f94b into master Oct 12, 2024
10 checks passed
@haarg haarg deleted the haarg/healthcheck branch October 12, 2024 02:42
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