Skip to content

Conversation

aaa4xu
Copy link
Contributor

@aaa4xu aaa4xu commented Aug 7, 2025

Description:

This PR fixes a regression where the GIT_COMMIT environment variable was no longer available in the final container image after a recent Dockerfile refactoring.

Please complete the following:

  • I have added screenshots for all UI updates
  • I process any text displayed to the user through translateText() and I've added it to the en.json file
  • I have added relevant tests to the test directory
  • I confirm I have thoroughly tested these changes and take full responsibility for any bugs introduced
  • I have read and accepted the CLA agreement (only required once).

Please put your Discord username so you can be contacted if a bug or regression is found:

aaa4xu

Copy link
Contributor

coderabbitai bot commented Aug 7, 2025

Walkthrough

The Dockerfile was updated to add a new build argument GIT_COMMIT with a default value "unknown" and an environment variable GIT_COMMIT set to this argument in the final image stage. No other changes were made to the installation or control flow.

Changes

Cohort / File(s) Change Summary
Dockerfile Build Metadata
Dockerfile
Added ARG GIT_COMMIT=unknown and ENV GIT_COMMIT="$GIT_COMMIT" in the final image stage.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Poem

A Dockerfile tweak, not too grand,
Now holds the commit at hand.
With GIT_COMMIT set,
Build info you’ll get—
A tiny change, simply planned!
🐳✨

Note

🔌 MCP (Model Context Protocol) integration is now available in Early Access!

Pro users can now connect to remote MCP servers under the Integrations page to get reviews and chat conversations that understand additional development context.


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 05afa63 and 7627f93.

📒 Files selected for processing (1)
  • Dockerfile (1 hunks)
✅ Files skipped from review due to trivial changes (1)
  • Dockerfile
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: 🔬 Test

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
Dockerfile (1)

53-54: Add an OCI label for easier metadata discovery
Setting org.opencontainers.image.revision helps tooling (docker inspect, registries, SBOM generators) find the commit without running the container.

 ARG GIT_COMMIT=unknown
 ENV GIT_COMMIT="$GIT_COMMIT"
+# OCI image metadata
+LABEL org.opencontainers.image.revision="$GIT_COMMIT"
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 63cb51a and 05afa63.

📒 Files selected for processing (1)
  • Dockerfile (1 hunks)
🧰 Additional context used
🧠 Learnings (1)
📓 Common learnings
Learnt from: andrewNiziolek
PR: openfrontio/OpenFrontIO#1007
File: resources/lang/de.json:115-115
Timestamp: 2025-06-02T14:27:37.609Z
Learning: For OpenFrontIO project: When localization keys are renamed in language JSON files, the maintainers separate technical changes from translation content updates. They wait for community translators to update the actual translation values rather than attempting to translate in the same PR. This allows technical changes to proceed while ensuring accurate translations from native speakers.
🔇 Additional comments (1)
Dockerfile (1)

53-54: Nice: commit info now survives into final image
Re-declaring the build arg in this stage is necessary because Docker resets ARG scope per stage. Promoting it to an ENV makes the value readable at runtime. Looks correct and solves the earlier regression.

coderabbitai[bot]
coderabbitai bot previously approved these changes Aug 7, 2025
@evanpelle evanpelle changed the base branch from main to v25 August 7, 2025 23:32
@evanpelle evanpelle dismissed coderabbitai[bot]’s stale review August 7, 2025 23:32

The base branch was changed.

@evanpelle evanpelle changed the base branch from v25 to main August 7, 2025 23:32
@evanpelle
Copy link
Collaborator

I think this should go into the v25 branch

scottanderson
scottanderson previously approved these changes Aug 8, 2025
@github-project-automation github-project-automation bot moved this from Triage to Final Review in OpenFront Release Management Aug 8, 2025
@scottanderson scottanderson changed the base branch from main to v25 August 8, 2025 00:11
@scottanderson scottanderson dismissed their stale review August 8, 2025 00:11

The base branch was changed.

@scottanderson scottanderson added this to the v25 milestone Aug 8, 2025
@scottanderson scottanderson added Bug Fix DevOps - CICD Continuous Integration and Continuous Delivery tools, including GitHub Actions labels Aug 8, 2025
@scottanderson scottanderson merged commit 7743c39 into openfrontio:v25 Aug 8, 2025
7 of 8 checks passed
@github-project-automation github-project-automation bot moved this from Final Review to Complete in OpenFront Release Management Aug 8, 2025
scottanderson pushed a commit that referenced this pull request Aug 18, 2025
## Description:
This PR fixes a regression where the `GIT_COMMIT` environment variable
was no longer available in the final container image after a recent
Dockerfile refactoring.

## Please complete the following:

- [X] I have added screenshots for all UI updates
- [X] I process any text displayed to the user through translateText()
and I've added it to the en.json file
- [X] I have added relevant tests to the test directory
- [X] I confirm I have thoroughly tested these changes and take full
responsibility for any bugs introduced
- [X] I have read and accepted the CLA agreement (only required once).

## Please put your Discord username so you can be contacted if a bug or
regression is found:

aaa4xu
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Fix DevOps - CICD Continuous Integration and Continuous Delivery tools, including GitHub Actions
Projects
Status: Complete
Development

Successfully merging this pull request may close these issues.

3 participants