Publish only :latest; consumer skill watches digest#10
Merged
Conversation
Switch the release model from "per-version tag + :latest" to ":latest only, identity = digest". Old versioned tags would just accumulate noise on Docker Hub; each `publish` creates a new immutable image digest that the consumer skill picks up via the registry API. ./security-scan.sh publish # builds multi-arch, pushes leverj/security-scan:latest ./security-scan.sh publish --no-push # release dry-run, build only What changed: - security-scan.sh: drop the [vX.Y.Z] positional arg and the versioned-tag output entirely. Push only :latest. Keep the pyproject/manifest version- alignment check — the `version` label inside the manifest is still the human-readable identifier, just not a docker tag anymore. After push, print the resulting image digest so the maintainer can confirm the skill will see it. - README + spec §15 + §16: updated to describe the new flow. Rollback becomes "pin a specific digest in the consumer's state" — the skill already stores pinned_digest for this. - pyproject.toml + __init__.py + manifest version bumped 0.2.2 -> 0.2.3. - Manifest changelog leads with the 0.2.3 release-flow note so the skill surfaces it on the upgrade prompt. Existing v0.2.0 / v0.2.1 / v0.2.2 tags on Docker Hub are not touched — they remain for historical reference. Nothing publishes new versioned tags going forward. Verified: 221 tests pass; ./security-scan.sh publish --no-push runs end- to-end with SBOM + provenance against the multi-arch builder. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
This PR changes the release/publish model for the leverj/security-scan Docker image: instead of pushing both vX.Y.Z and :latest, it now publishes only :latest and treats the image digest as the immutable identity that consumers watch.
Changes:
- Update
security-scan.sh publishto remove version/tag arguments, always push:latest, and print the resulting digest after publish. - Update docs/spec to describe digest-based release detection and rollback via digest pinning.
- Bump the scanner’s human-readable version from
0.2.2→0.2.3across code + manifest.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| security-scan.sh | Drops versioned tag publishing, enforces version alignment, pushes :latest, and attempts to surface the pushed digest. |
| security-scan-spec.md | Updates the image contract and release workflow docs to match digest-identity + :latest-only publishing. |
| SECURITY-SCAN-MANIFEST.yaml | Bumps manifest version/release notes to 0.2.3 and documents the new publish flow in changelog. |
| security_scan/init.py | Bumps package __version__ to 0.2.3. |
| README.md | Updates publish instructions and rationale for :latest-only + digest identity. |
| pyproject.toml | Bumps project version to 0.2.3. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+234
to
+237
| # Surface the new digest so the user can verify the skill picks it up. | ||
| local digest | ||
| digest="$(docker buildx imagetools inspect "$image_latest" 2>/dev/null | grep -E '^Digest:' | head -1 | awk '{print $2}')" | ||
| [[ -n "$digest" ]] && echo "digest: $digest" |
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.
Summary
Switch the release model from "per-version tag + :latest" to ":latest only, identity = digest". Old versioned tags accumulate as noise on Docker Hub; each `publish` creates a new immutable digest that the consumer skill picks up.
What changed
Existing v0.2.0 / v0.2.1 / v0.2.2 tags on Docker Hub aren't touched — they stay for historical reference. Nothing publishes new versioned tags going forward.
Companion change (ai-skills)
A separate commit will update the `feat/security-scan-skill` branch over in `leverj/ai-skills` so the SKILL.md uses digest comparison (querying Docker Hub's tags/latest endpoint or `docker manifest inspect` for `.images[0].digest`) instead of listing tags.
Test plan
🤖 Generated with Claude Code