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

Move /health endpoint to /api/v1/health (making it public) #716

Merged
merged 1 commit into from
Sep 24, 2024

Conversation

jake-low
Copy link
Contributor

Currently the /health endpoint is not publicly accessible because the nginx config only proxies requests to the backend if they start with /api. This change moves the /health healthcheck endpoint to /api/v1/health, thus making it public facing.

OSM US is starting to use updown.io to check the liveness of various services. Currently we've configured alerts for if https://osmcha.org isn't available, but we haven't set up anything to check that the OSMCha API itself is alive. Once this health check endpoint is available publicly, we can use that to monitor the API server.

I added a redirect from /health to /api/v1/health. The only current consumer of the /health endpoint is Kubernetes' liveness check. Once that's updated to use /api/v1/health we can remove the redirect; I only added it so that this change wouldn't break prod if we forgot to also update the helm chart before redeploying.

This allows us to monitor the API health more easily from a remote
service such as updown.io.
@jake-low jake-low merged commit 8f8611e into master Sep 24, 2024
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.

2 participants