Move /health endpoint to /api/v1/health (making it public) #716
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.