Organization-wide environment variables


When I need a specific environment variable for all of my pipelines, I have to either a) update every yaml file in every repo, or b) update every pipeline’s own environment. This is unconvincing. Since, environment variable is static and valid for all pipelines.

Is it possible to define organization-wide environment variables that can be used with all pipelines? Just like GitHub Actions does?


You can do it in script.

@xiaket You mean on EC2? Elastic AWS Plugin?

This is an interesting idea, but unfortunately it’s not something Buildkite supports at this stage.

This feature request, it may be worth combining your votes on there to help raise it’s profile.

For now, @xiaket has suggested a good option that we support. The agents can have environment variables set in the environment hook(, and depending on the variety of agents you’re running it may be feasible to set environment variables in a small number of hook scripts to add them into all builds.