You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
The slug of a pipeline is derived from its name—name attribute in terraform.
This means that if you decide to change the display name of an existing pipeline at some point, this will also changes its slug. As a result:
The URL of the pipeline page on the web, so any existing reference to the old URL (e.g. in our team's doc) would have to be udated
Since the slug is used as an identifier for the pipeline in many context, all of those will need to be updated as well (e.g. scripts that use the API that needs the slug to identify the pipeline, GraphQL queries, etc)
In particular, the elastic-ci-stack-s3-secrets-hooks plugin uses the slug of the pipeline to fetch the proper secrets (SSH clone keys, env vars…) for a pipeline in S3, which means changing the name of a pipeline will break it and make it stop finding those secrets and thus stop working just because the slug changed under us.
Describe the solution you'd like
It would be nice if the slug would only be derived from the name if not provided explicitly in the terraform resource, but would otherwise be read-write.
So in particular, creating the pipeline resource via this code would make the slug of the created pipeline be derived to my-project:
resource"buildkite_pipeline""my-project-pipeline" {
name="My Project"# no `slug = …` attribute provided explicitly, so it will be derived from `name` to be `my-project` implicitly
…
}
And changing the name terraform attribute later to name = "My Awesome Project" would update the slug to my-awesome-project. So far, just like today, no change there.
But specifying the slug a an explicit attribute in the terraform resource would allow us to override its derived value, so:
would allow us to still reference that pipeline with the slug my-project, even if the human-readable display name used in the Buildkite web portal etc. would be "My Awesome Project".
This would allow to give the option to decouple the display name of a pipeline from its slug, all while keeping the current behavior of having the slug derived by default if not provided explicitly.
This would avoid the risk of accidentally breaking pipelines when changing their display name, given a lot of things (like S3 secrets plugin) rely on the slug as an sort of identifier for the pipeline.
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
The
slug
of a pipeline is derived from its name—name
attribute in terraform.This means that if you decide to change the display name of an existing pipeline at some point, this will also changes its
slug
. As a result:slug
is used as an identifier for the pipeline in many context, all of those will need to be updated as well (e.g. scripts that use the API that needs the slug to identify the pipeline, GraphQL queries, etc)slug
of the pipeline to fetch the proper secrets (SSH clone keys, env vars…) for a pipeline in S3, which means changing the name of a pipeline will break it and make it stop finding those secrets and thus stop working just because theslug
changed under us.Describe the solution you'd like
It would be nice if the
slug
would only be derived from thename
if not provided explicitly in theterraform
resource, but would otherwise be read-write.So in particular, creating the pipeline resource via this code would make the
slug
of the created pipeline be derived tomy-project
:And changing the
name
terraform attribute later toname = "My Awesome Project"
would update theslug
tomy-awesome-project
. So far, just like today, no change there.But specifying the
slug
a an explicit attribute in the terraform resource would allow us to override its derived value, so:would allow us to still reference that pipeline with the slug
my-project
, even if the human-readable display name used in the Buildkite web portal etc. would be "My Awesome Project".This would allow to give the option to decouple the display name of a pipeline from its
slug
, all while keeping the current behavior of having the slug derived by default if not provided explicitly.Describe alternatives you've considered
N/A
Additional context
This is a follow-up of this thread in the support forums: https://forum.buildkite.community/t/decouple-pipeline-name-from-logical-reference-slug/1414/6 cc @benmc
Potential impact
This would avoid the risk of accidentally breaking pipelines when changing their display name, given a lot of things (like S3 secrets plugin) rely on the
slug
as an sort of identifier for the pipeline.The text was updated successfully, but these errors were encountered: