# LukeMathWalker/cargo-chef

A cargo-subcommand to speed up Rust Docker builds using Docker layer caching.

Repository: https://github.com/LukeMathWalker/cargo-chef
Canonical: https://ross.abutalabs.com/products/cargo-chef
Language: Rust
License: Apache-2.0
License Family: permissive
Topics: rust, docker, cargo, ci
Last push: 2026-08-12T06:19:27+00:00

## Health v2 (maintenance only)
Score: 89/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 97, release rhythm 73, longevity 100
- inputs: {"age_days": 2144, "days_push": 21, "days_rel": 21, "gap_med": 94, "n_releases_24m": 10}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2690, forks 143 (observed 2026-08-28T04:07:10.935780+00:00)

## What it is
cargo-chef is a cargo subcommand that speeds up Rust Docker builds by exploiting Docker layer caching. It extracts a recipe of the project's dependency manifests, builds dependencies in a separate cached layer, and avoids recompiling them when only source code changes.

## Use cases
- speed up Rust Docker builds with layer caching
- cache Rust dependencies in Docker images
- avoid recompiling crates when only source changes
- optimize CI builds for Rust containers
- generate a requirements.txt-like recipe for Rust dependencies

## When to choose
- you build Rust projects in Docker and rebuilds are slow
- your CI pipeline rebuilds Rust dependencies on every commit
- you want faster container image builds without restructuring your Dockerfile manually

## When to avoid
- you don't build Rust in containers
- you want a tool to run locally on an existing codebase (it's designed for Docker build contexts)
- you use a build system that already caches dependencies effectively

## Facets
- artifact type: cli-tool
- maturity: active
- function: build-tool, caching, cli, deployment
- domain: developer-tools
- platform: cli, windows
- tags: cargo-subcommand, docker-layer-caching, rust-builds, container-images, devops, containers, command-line, docker, linux, macos

## Member repositories
- LukeMathWalker/cargo-chef (main) score 89

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:07:10.935780+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T02:16:34.377248+00:00, confidence not recorded.
  - readme: https://github.com/LukeMathWalker/cargo-chef (fetched 2026-08-28T04:07:10.935780+00:00, sha 5e305e5d766d)
  - registry_crates: https://crates.io/api/v1/crates/cargo-chef (fetched 2026-08-29T09:59:35.721001+00:00, sha 45e952d699d9)
- Data as of 2026-08-30T08:39:29.467469+00:00.
