Skip to content

Conversation

@ddlees
Copy link
Member

@ddlees ddlees commented Aug 8, 2025

Summary by CodeRabbit

  • Chores
    • Updated workflow to support publishing images to both GitHub Container Registry (GHCR) and Azure Container Registry (ACR).
    • Added authentication steps for ACR in the publishing process.

@coderabbitai
Copy link

coderabbitai bot commented Aug 8, 2025

Walkthrough

The workflow configuration for publishing containers was updated to support both GitHub Container Registry (GHCR) and Azure Container Registry (ACR). This includes adding a login step for ACR and modifying the metadata extraction to handle both registries. No changes were made to exported or public code entities.

Changes

Cohort / File(s) Change Summary
Workflow: Container Registry Publishing
.github/workflows/publish.yml
Renamed GHCR login step, added ACR login step using Azure credentials, and updated metadata extraction to include both GHCR and ACR repositories.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Poem

🐇
Two registries now in sync,
GHCR and Azure—link by link.
Secrets stored and logins new,
Metadata knows just what to do.
Containers hop from cloud to cloud,
This bunny’s feeling extra proud!
🚀

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 736891b and d0edf0b.

📒 Files selected for processing (1)
  • .github/workflows/publish.yml (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • .github/workflows/publish.yml
⏰ 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
✨ Finishing Touches
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch acr-image-publish

🪧 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 docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai generate unit tests to generate unit tests for 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

@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: 2

🧹 Nitpick comments (1)
.github/workflows/publish.yml (1)

158-164: Prefer GITHUB_TOKEN over PAT for GHCR and update the action version

Use GitHub’s OIDC-scoped GITHUB_TOKEN instead of a PAT and modernize the login action. This reduces secret sprawl and aligns with least-privilege.

-      - name: Log in to GHCR
-        uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
-        with:
-          registry: ghcr.io
-          username: ${{ secrets.GHCR_USER }}
-          password: ${{ secrets.PACKAGE_SCOPE }}
+      - name: Log in to GHCR
+        uses: docker/login-action@v3
+        with:
+          registry: ghcr.io
+          username: ${{ github.actor }}
+          password: ${{ secrets.GITHUB_TOKEN }}

Note: If you prefer pinning by commit for supply-chain hardening, replace @v3 with the corresponding commit SHA.

📜 Review details

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

📥 Commits

Reviewing files that changed from the base of the PR and between 361ba8f and 736891b.

📒 Files selected for processing (1)
  • .github/workflows/publish.yml (1 hunks)

Comment on lines +165 to +171
- name: Log in to ACR
uses: azure/docker-login@v1
with:
login-server: ${{ secrets.ACR_AZUREHOUND_REGISTRY_URL }}
username: ${{ secrets.ACR_CLIENT_ID }}
password: ${{ secrets.ACR_SECRET }}

Copy link

Choose a reason for hiding this comment

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

💡 Verification agent

❓ Verification inconclusive

Pin azure/docker-login and validate login-server format

  • Pin the action to a commit SHA to mitigate supply-chain risk.
  • Ensure ${{ secrets.ACR_AZUREHOUND_REGISTRY_URL }} is host-only without scheme (e.g., myregistry.azurecr.io), as required by the action.
-      - name: Log in to ACR
-        uses: azure/docker-login@v1
+      - name: Log in to ACR
+        uses: azure/docker-login@<commit-sha>
         with:
           login-server: ${{ secrets.ACR_AZUREHOUND_REGISTRY_URL }}
           username: ${{ secrets.ACR_CLIENT_ID }}
           password: ${{ secrets.ACR_SECRET }}

Optional: Consider migrating to federated credentials (OIDC) with azure/login@v2 + az acr login to drop the client secret entirely. Want a sample? I can provide one.


Pin azure/docker-login and validate ACR registry URL

  • In .github/workflows/publish.yml (lines 165–171):
    • Pin azure/docker-login to a specific commit SHA instead of a floating version.
    • Ensure ${{ secrets.ACR_AZUREHOUND_REGISTRY_URL }} contains only the hostname (e.g. myregistry.azurecr.io) with no URL scheme.

Suggested diff:

-      - name: Log in to ACR
-        uses: azure/docker-login@v1
+      - name: Log in to ACR
+        uses: azure/docker-login@<commit-sha>
         with:
           login-server: ${{ secrets.ACR_AZUREHOUND_REGISTRY_URL }}
           username: ${{ secrets.ACR_CLIENT_ID }}
           password: ${{ secrets.ACR_SECRET }}

Optional: To eliminate the client secret altogether, consider swapping to OIDC-based login using azure/login@v2 + az acr login. Let me know if you’d like a config example!

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
- name: Log in to ACR
uses: azure/docker-login@v1
with:
login-server: ${{ secrets.ACR_AZUREHOUND_REGISTRY_URL }}
username: ${{ secrets.ACR_CLIENT_ID }}
password: ${{ secrets.ACR_SECRET }}
- name: Log in to ACR
uses: azure/docker-login@<commit-sha>
with:
login-server: ${{ secrets.ACR_AZUREHOUND_REGISTRY_URL }}
username: ${{ secrets.ACR_CLIENT_ID }}
password: ${{ secrets.ACR_SECRET }}
🤖 Prompt for AI Agents
In .github/workflows/publish.yml around lines 165 to 171, update the
azure/docker-login action to use a specific commit SHA instead of the floating
v1 version to ensure stability. Also, verify that the secret
ACR_AZUREHOUND_REGISTRY_URL contains only the registry hostname without any URL
scheme like https://. Optionally, consider replacing this login step with an
OIDC-based login using azure/login@v2 and az acr login to avoid using client
secrets.

@ddlees ddlees changed the title Update publish.yml cd: publish stable images to azure container registry Aug 8, 2025
@ddlees ddlees merged commit 8f3d524 into main Aug 8, 2025
18 of 19 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Aug 8, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants