Skip to main content
Set up a remote cache for Pantsbuild. Namespace provides high-performance remote caching with very low network latency between runners and the cache storage. This allows your Pantsbuild workflows to reuse build artifacts across runs, irrespective of your chosen granularity, significantly reducing build times. cache pants setup sets up a remote cache for Pantsbuild and generates a pants.toml to use it. Learn more about Pantsbuild caching →

Usage

Example

The following example creates a remote cache and uses it during a Pantsbuild invocation.
1

Configure the remote cache

Generate a Pants configuration for the remote cache:
2

Run tests

Use the generated configuration during a Pants invocation:

Options

—pants-toml

If specified, write the toml to this path.
Last modified on August 20, 2026