Expose deployed commit sha at /info/release - #995
Merged
Merged
Conversation
Previously the only way to find out which commit an environment was running was the Heroku platform API, which needs credentials broad enough to change the app. GitHub has some deployment information, but only for staging as production releases are promoted. This change adds a public InfoController with a /info/release route that renders HEROKU_SLUG_COMMIT as plain text, falling back to "unknown" when the variable is unset. The editor dashboard will read it to show the currently deployed version of the API. The same variable already tags log lines in config/application.rb, so no new configuration is introduced. The endpoint is unauthenticated and inherits from ActionController::API so it does not require a session; the commit sha is already public in the open source repository.
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The endpoint should handle blank HEROKU_SLUG_COMMIT values (and related regression coverage), and the access-control expectations for a new public route need to be clarified.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
Adds a lightweight “release info” endpoint to the Rails monolith so external tooling (e.g., the editor dashboard) can read which commit SHA is currently deployed.
Changes:
- Adds
GET /info/releaseroute. - Introduces
InfoController#releaseto return the deployed commit SHA as plain text (orunknown). - Adds request specs covering the env-var-present and env-var-missing cases.
File summaries
| File | Description |
|---|---|
spec/requests/info_controller_spec.rb |
Adds request coverage for the new /info/release endpoint response body. |
config/routes.rb |
Wires up the new GET /info/release route. |
app/controllers/info_controller.rb |
Implements the endpoint that returns the deployed SHA as plain text. |
Review details
- Files reviewed: 3/3 changed files
- Comments generated: 3
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Test coverage93.51% line coverage reported by SimpleCov. |
raspberrypiherokubot
temporarily deployed
to
editor-api-p-release-in-0v0iw1
September 2, 2026 12:59
Inactive
jamiebenstead
approved these changes
Sep 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What's changed?
This adds an info/release route that shows the current git sha for the release.
I intend to use this from the editor dashboard to show what apps need deploying.
After deploy: