fix: ensure 'latest' Docker tag points only to releases#50
Conversation
- Add flavor.latest=false to disable automatic latest tag - Change main branch tag from 'latest' to 'edge' - Add explicit 'latest' tag only for version tags (refs/tags/v*) - Update security scan to use 'edge' tag for main branch builds Fixes #42
- Update "Available Images" section to reflect new tagging strategy - Document 'latest' tag as latest stable release - Document 'edge' tag as main branch development builds Related to #42
- Fix indentation consistency in docker-publish.yml and release.yml - Standardize quote style to double quotes - Add missing newline at end of docker-publish.yml
- Update github/codeql-action/upload-sarif from v3 to v4 - Fixes deprecation warning
📝 WalkthroughSummary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings. WalkthroughThis pull request restructures the Docker publish workflow to ensure the Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Fix all issues with AI agents
In @.github/workflows/docker-publish.yml:
- Around line 107-113: The workflow step "Run security scan on image" currently
uses aquasecurity/trivy-action@master which is a supply-chain risk; update the
uses entry for that step to pin a fixed release tag or commit SHA (e.g., change
aquasecurity/trivy-action@master to aquasecurity/trivy-action@vX.Y.Z or
aquasecurity/trivy-action@<commit-sha>) so the action version is immutable and
won't change unexpectedly.
📜 Review details
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
.github/workflows/docker-publish.yml.github/workflows/release.ymlREADME.md
🔇 Additional comments (4)
.github/workflows/release.yml (1)
6-6: LGTM!The formatting changes (single to double quotes, comment spacing) are cosmetic and maintain consistency across workflow files. The
check-name: "build"correctly references the job name defined indocker-publish.yml.Also applies to: 10-10, 29-29, 86-86
.github/workflows/docker-publish.yml (2)
64-73: LGTM! Tagging strategy correctly implements the PR objective.The metadata configuration properly:
- Disables automatic
latesttagging withflavor: latest=false- Tags main branch builds with
edgeviatype=raw,value=edge,enable={{is_default_branch}}- Applies
latestonly for version tags viatype=raw,value=latest,enable=${{ startsWith(github.ref, 'refs/tags/v') }}This ensures
latestalways points to the most recent release whileedgetracks the development branch.
90-105: LGTM!The scan tag determination logic correctly mirrors the tagging strategy - using the version tag for releases and
edgefor main branch builds. The lowercase conversion ensures registry compatibility.README.md (1)
318-319: LGTM!The documentation clearly explains the distinction between
latest(stable releases for production) andedge(development builds from main). This aligns well with the workflow changes and helps users make informed choices about which tag to use.
This pull request updates the Docker image tagging strategy to better distinguish between stable releases and development builds. The changes clarify which tags are used for production versus development images, both in the build workflow and in the documentation.
Docker Workflow Tagging Changes:
.github/workflows/docker-publish.ymlso that:latesttag is now only applied to images built from release tags (i.e., stable releases), not from the default branch.edgetag is now used for images built from the default branch (main), representing the latest development build.edgetag for non-tag pushes and the version tag for release builds.Documentation Updates:
README.mdto clarify the meaning of thelatestandedgetags:latestis now described as the latest stable release, recommended for production.edgeis described as the development build from the main branch, which may be unstable.Resolves #42