Skip to content
Latchkey

Blacksmith Docker Layer Cache: Cold First Run vs Reuse

If your first Blacksmith Docker build is slow, that is expected. The first run is uncached; every subsequent run mounts the hydrated layer cache.

According to Blacksmith's Docker caching docs, once you switch to Blacksmith's Docker actions the first Docker run will be an uncached run, and every subsequent run will have the hydrated layer cache mounted into your runners. The cache lives on NVMe-backed sticky disks, and Docker will only rebuild from the layer that has changed and use the cached layers for the rest of the image.

Why the first run is slow (and later ones are fast)

There is nothing to reuse on the first build, so it runs cold. After that, Blacksmith's docs report improvements ranging from 2x to 40x depending on the workload, because unchanged layers come from the mounted cache instead of being rebuilt.

Why layers might not reuse

  • A change early in the Dockerfile invalidates every layer after it, so order stable steps first.
  • The persistent cache lives on a sticky disk that, per the docs, is evicted after 7 days of inactivity, so infrequent pipelines can go cold again.
  • Only the Blacksmith Docker actions populate the Blacksmith cache (covered on the setup page).

Self-healing is a different problem

Cold-start slowness is a caching behavior, not a failure. Latchkey's focus is a separate class of pain: when a Docker build fails for transient reasons such as a registry timeout or a disk-full error, self-healing retries it automatically instead of failing the pipeline.

If you want failures to recover on their own

Blacksmith is a strong choice when raw runner speed and per-core performance are your priority. If your recurring pain is instead flaky, transient failures that force manual re-runs, Latchkey is worth a look: it runs your GitHub Actions on managed, drop-in runners and adds self-healing CI, so out-of-memory kills, disk-full errors, and registry timeouts are detected and retried automatically. You can pilot it on a single workflow with a one-line runs-on change and compare against your real builds.

Frequently asked questions

Where do these Blacksmith details come from?
The Blacksmith specifics on this page are drawn from Blacksmith's own documentation and pricing page as reviewed on 2026-07-02: https://docs.blacksmith.sh/blacksmith-caching/docker-builds.md. Blacksmith updates its product and pricing over time, so verify current details on their site before you rely on them.

Related guides

See what you would save - Latchkey managed runners with self-healing. Start free →