Buildkite Agent v4.0.0
Buildkite Agent v4 is now stable. Most features and fixes developed since v3 and v4 diverged were backported to v3, so this changelog focuses on behaviour that differs from v3.
Review the v3 to v4 upgrade guide before upgrading.
Important
v4 removes a number of deprecated flags, environment variables, configuration options, and experiments. Removed flags fail loudly; removed environment variables and configuration options fail silently. See Removed flags, environment variables, and configuration options at the end of the breaking changes below, and the v3 to v4 upgrade guide for the full list.
Breaking changes
Job handling
- Removed the deprecated built-in Docker integration. The
dockeranddocker-composeplugins remain supported. - Cancelled Windows jobs now return exit status
1instead of0. - Replaced
cancel-grace-periodandsignal-grace-period-secondswithcancel-signal-timeoutandcancel-cleanup-timeout, defaulting to 10 and 5 seconds respectively.
Job logs
The agent now always emits ANSI timestamp codes. Plaintext timestamps and the option to disable ANSI timestamps have been removed.
Checkout
BUILDKITE_COMMITis resolved to a commit hash after checkout.- Replaced built-in SSH key scanning and
known-hostsmanagement with OpenSSH host-key-checking options. - Git commit verification now defaults to
strictand accepts onlystrictoroff. Replace previous empty orwarnvalues before upgrading.
Agent parallelism
spawn-with-priority now accepts static, ascending, or descending. Boolean values are no longer accepted, and passing one prevents the agent from starting.
Observability
- Removed OpenTracing, direct DogStatsD support, and Datadog-specific tracing workarounds. Use OpenTelemetry instead.
- Renamed
tracing-service-nametotelemetry-service-name. - Trace-parent propagation is now always enabled.
- Replaced
jobs.successandjobs.failedwithjobs.finished. - Replaced
jobs.duration.successandjobs.duration.errorwithjobs.duration. - Use the
exit_codeattribute to distinguish successful and failed jobs. - The standard Prometheus job metrics now include
priorityandqueuelabels, replacing the separate_with_labels_totalmetrics.
Pipeline uploads
- Removed the
--reject-secretsflag (BUILDKITE_AGENT_PIPELINE_UPLOAD_REJECT_SECRETS). Rejecting secrets is now the default, so the flag is redundant — butbuildkite-agent pipeline upload --reject-secretsno longer runs. It exits immediately withfatal: flag provided but not defined: -reject-secrets. Remove the flag before upgrading, including from any wrapper scripts, plugins, or tooling that shells out topipeline upload. - Pipeline uploads now reject interpolated secrets by default. To permit them, use
--allow-secrets(BUILDKITE_AGENT_PIPELINE_UPLOAD_ALLOW_SECRETS). - Secret detection now includes trigger-step
build.envvalues.
Artifacts
- Windows artifact paths are now stored with
/separators. - Removed
artifact upload --follow-symlinks; use--glob-resolve-follow-symlinks. - Artifact downloads now unconditionally prevent path traversal.
Plugins and hooks
- Removed deprecated plugin configuration environment-variable aliases that collapsed consecutive underscores.
post-checkout,post-command, andpre-exithooks now run in reverse setup order: plugins last-to-first, repository, then agent.- Enable the
legacy-post-hook-orderexperiment to temporarily restore v3 ordering.
Command behaviour
oidc request-tokennow exits with status77for definitive API refusals using HTTP status 400, 401, 403, 404, 410, or 422. Other failures continue to exit with status1.
Removed flags, environment variables, and configuration options
v4 removes a number of deprecated flags, environment variables, agent configuration options, and experiments. The upgrade guide lists all of them with their replacements.
How they fail depends on how you set them:
- Flags fail loudly.
buildkite-agentexits immediately withfatal: flag provided but not defined, before running any work. A single stale flag in a pipeline or hook breaks the build on the first command. - Environment variables and agent configuration file options fail silently. The agent starts normally and the setting is ignored, so behaviour changes with no error and no warning.
Before upgrading, check the guide's list against your pipelines, hooks, plugins, agent configuration files, and any tooling that shells out to buildkite-agent.
Other changes
- Added Linux systemd watchdog support based on successful Buildkite heartbeat activity.
- Added an Ubuntu 26.04 agent Docker image.
New Contributors
- @JoeColeman95 made their first contribution in #4232
- @Temikus made their first contribution in #4239
Full Changelog: v3.136.0...v4.0.0