verify-buildkit-cache

Installation
SKILL.md

Verifying BuildKit Cache Effectiveness

Systematically verify—from CI logs only—that Docker RUN --mount=type=cache (Go GOMODCACHE and GOCACHE) is:

  1. Persisted across jobs
  2. Restored by GitHub Actions
  3. Injected back into BuildKit
  4. Actually speeding up go build

Prerequisites

This checklist assumes:

  • Dockerfile uses BuildKit cache mounts:
    • RUN --mount=type=cache,target=/go/pkg/mod (GOMODCACHE)
    • RUN --mount=type=cache,target=/root/.cache/go-build (GOCACHE)
  • GitHub Actions workflow:
    • Uses actions/cache@v5 to persist a host directory (CACHE_DIR, e.g. cache-mount/)
Related skills
Installs
5
GitHub Stars
126
First Seen
Mar 1, 2026