Buildkite Agent improvements
Checkout
- Skip checkout on any agent by setting
BUILDKITE_SKIP_CHECKOUT=true— no plugin or workaround required. Previously this meant clearingBUILDKITE_REPO, using a checkout plugin, or (in the Agent Stack for Kubernetes) settingcheckout: skip: true. - Skip fetching commits you already have with
--git-skip-fetch-existing-commits, which skips thegit fetchstep during checkout when the target commit already exists locally. This saves time and network I/O on every build where the commit is already available, which is especially useful for agents using git mirrors. - Bound how long a checkout attempt can run with
--git-checkout-timeout(orBUILDKITE_GIT_CHECKOUT_TIMEOUT), specified in seconds. A hung git operation (clone, fetch, checkout, or submodule update) would previously wedge a job indefinitely; now an attempt that exceeds the timeout is cancelled and handed to the agent's existing checkout retry loop instead of blocking forever. The default is0, which keeps the current behavior of waiting indefinitely. - Control submodule cloning per pipeline or step by setting
BUILDKITE_GIT_SUBMODULESat the pipeline or step level (or via a hook), without needing to reconfigure your agents.
Artifacts
- Faster downloads from your own S3 buckets. The agent splits each download into parallel ranged requests (a multipart download) instead of fetching the object as a single stream, which significantly speeds up downloads of large artifacts. This is enabled by default; you can opt out with
--no-s3-multipart-download(orBUILDKITE_NO_S3_MULTIPART_DOWNLOAD). - Tunable upload concurrency. Uploads have always run in parallel, but the number of concurrent uploads was fixed to the agent's CPU count, which can be a bottleneck for jobs that upload many small files, where wall time is dominated by per-request latency rather than CPU work. The default is unchanged, so existing agents behave exactly as before, but you can now raise (or lower) the limit with
--concurrencyonbuildkite-agent artifact upload, theBUILDKITE_ARTIFACT_UPLOAD_CONCURRENCYenvironment variable, or fleet-wide viaagent start --artifact-upload-concurrency.
More agent improvements
- More control over
if_changedduringpipeline upload. The--fetch-diff-baseflag (orBUILDKITE_FETCH_DIFF_BASE) ensures the agent fetches the configured diff base before computing the file diff, so the local repository has an up-to-date copy of the base branch. The--changed-files-pathflag (orBUILDKITE_CHANGED_FILES_PATH) lets you supply a pre-computed list of changed files instead of relying on git commands to detect changes. - Hooks can detect job timeouts. The agent sets
BUILDKITE_JOB_TIMED_OUT=truein the post-command hook environment when a job hits its timeout, so your hooks can distinguish a timeout from other cancellation reasons and react accordingly (for example, to send a specific notification or clean up differently). - Fail fast on missing cloud tags with
--fail-on-missing-tags(orBUILDKITE_AGENT_FAIL_ON_MISSING_TAGS), which exits the agent on startup if an enabled cloud tag source (EC2, ECS, or GCP) fails to return tags. Without this, an agent that fails to read its instance tags — for example due to cloud API rate limiting — would still connect to Buildkite but be misrouted or unusable for builds that rely on tag-based targeting. Failing fast makes the problem obvious and easy to diagnose.
These improvements rolled out across several agent releases. Update to Buildkite Agent v3.127.2 or later to take advantage of all of them. See the agent release notes for the complete list of changes.
Buildkite
Start turning complexity into an advantage
Create an account to get started for free.