Skip to content

ci(docker): use zstd compression for release images#281

Merged
SantiagoDePolonia merged 1 commit into
mainfrom
ci/docker-zstd-level-3
Apr 26, 2026
Merged

ci(docker): use zstd compression for release images#281
SantiagoDePolonia merged 1 commit into
mainfrom
ci/docker-zstd-level-3

Conversation

@SantiagoDePolonia

@SantiagoDePolonia SantiagoDePolonia commented Apr 26, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Enable zstd compression for release Docker image exports
  • Use compression level 3 and force recompression for release layers

Validation

  • pre-commit checks from git commit passed

Summary by CodeRabbit

  • Chores
    • Optimized Docker image layer compression in the release workflow to improve build efficiency.

@coderabbitai

coderabbitai Bot commented Apr 26, 2026

Copy link
Copy Markdown
Contributor
📝 Walkthrough

Walkthrough

The Docker build-and-push step in the GitHub Actions release workflow now includes Zstd compression (level 3) and force-compression settings in the Buildx outputs configuration, replacing the previous digest-only pushing approach.

Changes

Cohort / File(s) Summary
Docker Build Configuration
.github/workflows/release.yml
Modified Buildx outputs configuration to add Zstd compression (level 3) and enable force-compression=true for Docker image layer compression during release builds.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related PRs

Poem

🐰 A rabbit hops with joy so bright,
Compression magic, done just right!
Zstd flows where digests once lived,
Smaller images, the gift it's give!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: enabling zstd compression for Docker release images, which aligns with the primary modification in the workflow configuration.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch ci/docker-zstd-level-3

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

Comment @coderabbitai help to get the list of available commands and usage tips.

@greptile-apps

greptile-apps Bot commented Apr 26, 2026

Copy link
Copy Markdown

Greptile Summary

This PR adds zstd compression (compression=zstd,compression-level=3,force-compression=true) to the Docker image export step in the release workflow, enabling more efficient layer storage and transfer for release images pushed to Docker Hub.

Confidence Score: 5/5

This PR is safe to merge — the change is a single-line CI tweak with no logic risk.

The only change is appending three well-documented Docker Buildx output options (compression, compression-level, force-compression) to an existing outputs string. All options are valid for the type=image exporter, Docker Hub supports zstd-compressed OCI layers, and the downstream imagetools create promotion step is unaffected. No P0/P1 findings exist.

No files require special attention.

Important Files Changed

Filename Overview
.github/workflows/release.yml Adds zstd compression options to the docker/build-push-action outputs parameter; change is syntactically correct and well-scoped.

Sequence Diagram

sequenceDiagram
    participant GHA as GitHub Actions
    participant Buildx as Docker Buildx
    participant DH as Docker Hub

    GHA->>Buildx: Build multi-platform image (amd64, arm64, arm/v7)
    Note over Buildx: compression=zstd<br/>compression-level=3<br/>force-compression=true
    Buildx->>DH: Push layer blobs (zstd-compressed) by digest
    DH-->>Buildx: Digest per platform
    Buildx-->>GHA: outputs.digest

    GHA->>Buildx: imagetools create (docker-promote)
    Note over Buildx: Assemble multi-arch manifest<br/>pointing to existing digests
    Buildx->>DH: Push manifest (semver + latest tags)
    DH-->>GHA: Tagged release published
Loading

Reviews (1): Last reviewed commit: "ci(docker): use zstd compression for rel..." | Re-trigger Greptile

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
.github/workflows/release.yml (1)

17-17: 🧹 Nitpick | 🔵 Trivial

Stale step name.

The job name still says "Build and push Docker image by digest" which is accurate, but worth noting this step now also dictates the on-wire compression for every published tag (since docker-promote uses imagetools create which copies blobs as-is). Consider updating the job description/comment to mention zstd so future readers understand why pulls behave differently across runtimes.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.github/workflows/release.yml at line 17, Update the job name/comment "Build
and push Docker image by digest" to reflect that it now also dictates on-wire
compression (zstd) for published tags; specifically, change the visible job name
or add a clarifying comment in the workflow so it mentions zstd/on-wire
compression and that docker-promote uses `imagetools create` which copies blobs
as-is, so pulls may differ across runtimes.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Outside diff comments:
In @.github/workflows/release.yml:
- Line 17: Update the job name/comment "Build and push Docker image by digest"
to reflect that it now also dictates on-wire compression (zstd) for published
tags; specifically, change the visible job name or add a clarifying comment in
the workflow so it mentions zstd/on-wire compression and that docker-promote
uses `imagetools create` which copies blobs as-is, so pulls may differ across
runtimes.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 98789765-86c3-4470-8c4c-da0c9146330a

📥 Commits

Reviewing files that changed from the base of the PR and between ca1be02 and a3d15a2.

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

@codecov-commenter

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@SantiagoDePolonia SantiagoDePolonia merged commit a42f04b into main Apr 26, 2026
19 checks passed
@SantiagoDePolonia SantiagoDePolonia deleted the ci/docker-zstd-level-3 branch June 11, 2026 09:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants