Skip to content

Conversation

@eswan18
Copy link
Owner

@eswan18 eswan18 commented Feb 8, 2026

Summary

  • Switches from docker build to docker buildx build with registry-based layer caching
  • Caches intermediate layers (notably the npm ci deps stage) across builds, saving ~1 min when dependencies haven't changed
  • Removes the separate push step (buildx --push handles it) and the redundant images block
  • Extracts image path into _IMAGE substitution to reduce repetition

How it works

Each build pushes cached layers to ...:cache-prod / ...:cache-staging tags. Subsequent builds pull those layers before building, so unchanged layers (like npm ci) are reused.

First build after this merges will be the same speed (no cache yet). Subsequent builds should save ~1 min.

Test plan

  • Merge and watch the Cloud Build log to confirm buildx runs successfully
  • Verify cached layers are used on the next build (look for "importing cache manifest" in logs)
  • Verify images are pushed and ArgoCD picks them up

🤖 Generated with Claude Code

Switches from docker build to docker buildx build with --cache-from
and --cache-to pointing to registry-based cache tags. This caches
intermediate layers (notably the npm ci deps stage) across builds,
saving ~1 min when package.json hasn't changed.

Also removes the separate push step (buildx --push handles it) and
the redundant images block.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@vercel
Copy link

vercel bot commented Feb 8, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
forecasting Error Error Feb 8, 2026 7:56pm

@eswan18 eswan18 merged commit 53dd120 into main Feb 8, 2026
1 of 3 checks passed
@eswan18 eswan18 deleted the feat/buildkit-layer-caching branch February 8, 2026 19:55
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.

1 participant