Configuration examples
To connect NativeLink to your Pantsbuild project, just add the code below to your pants.toml file. If you can’t find a pants.toml file - create one in the root directory of your Pantsbuild project.
-
Configure your
pants.toml- Copy the following lines into your
pants.toml:[GLOBAL]remote_cache_read = trueremote_cache_write = trueremote_store_address = "[REMOTE_STORE_ADDRESS]"[GLOBAL.remote_store_headers]x-nativelink-api-key = "[API_KEY]"
- Copy the following lines into your
-
Validate Connection
- Once you’ve added those lines to your
pants.toml, run the following command to execute a build:pants --no-pantsd --level=trace --no-local-cache test :: - You will see remote cache utilization on the Dashboard page if your
pants.tomlis configured correctly.
- Once you’ve added those lines to your