Skip to main content
aspect ci warming requires Aspect CLI v2026.39.10 or newer (pinned via .aspect/version.axl). For the legacy rosetta run warming task, see ; to move over, follow the migration guide.

How warming works

Aspect Workflows CI runners are persistent: a runner reuses its caches across the jobs it serves. When a runner group scales up, a new runner starts cold, and its first job has to fetch every external repository and run each repository rule before Bazel can analyze anything. Warming front-loads that work:
  1. A scheduled warming job, typically on main, runs aspect ci warming. The task runs the runner health check, clears the previous Bazel state on the runner’s storage mount, and runs bazel build --nobuild on the target patterns. That fetches external repositories, runs repository rules, and loads and analyzes the targets; no build actions execute. The task then uploads the repository cache, output base, and Bazel caches as the archive for the runner group’s warming set.
  2. A new runner restores the latest archive for its warming set while it boots. The first job’s health check waits for the restore to finish before Bazel starts. To hold the CI agent until the restore finishes instead, set wait_for_warming, or ask Aspect to on a deployment hosted by Aspect (off by default; see ).
  3. That first bazel build or bazel test starts with external repositories fetched and repository rules run.
Warming doesn’t populate the remote cache: build outputs still come from the remote cache or are built by the job. An archive restores only on runners booted from the same machine image it was created on, so after a runner image upgrade, new runners boot cold until the next warming job runs. The archive also carries the Aspect CLI’s download caches, so a warm runner doesn’t re-fetch the CLI.

Turning it on

Warming is enabled per runner group, and each group that needs different caches gets its own warming set: one for a group that also restores a pnpm store or Poetry environments, another for a group on a different CPU architecture. On a deployment hosted by Aspect, ask for the groups you want warmed. On a self-hosted deployment, set warming = true on the group in Terraform; see .

Configure the warming job

Add a scheduled job that runs aspect ci warming on the runner group you want warm, against your main branch, once or twice a day. Each warming set needs its own job, on a runner group that uses that set. With no target patterns, the task warms ..., every target in the package at and beneath the current directory. The examples pass //... explicitly, and schedule the job daily at 12:00 UTC (0 12 * * *); adjust the time to your team’s working hours. For the full set of flags and target options, see aspect ci warming.
The warming task doesn’t need the setup-aspect step: it runs on an Aspect Workflows CI runner, where aspect is already on the PATH. The GitHub Actions example still uses the action because it provides the auth aspect needs to post its status check; on other providers, supply ASPECT_API_TOKEN instead (see the comments in the examples).
.github/workflows/aspect-workflows-warming.yaml