Forum Discussion

msherms's avatar
msherms
Copper Contributor
Sep 27, 2023

Why does having a file named azure-pipelines.yml create a new pipeline?

Our development and build environment in production is going through some changes to easily allow builds to occur on a test instance of Azure DevOps by ghosting the production git repositories over the existing ones in the related test instance. So, for each repository in a project, repos that exist in production are cloned into the test and then severed, to make sure the most recent sources can be tested with test builds.

 

When cloning the git repos into the test, I notice any repo that has the yaml pipeline file named "azure-pipelines.yml" automatically creates a CI pipeline. Not only does it of course not work, but it's completely undesirable, and as far as i can find, undocumented. Folders that have a YML file named anything other than that don't do that.

 

Why is this a thing? I don't see why anyone would ever want that, especially based on a magic string name. Am i missing something? If not, can we get an option in settings on the server/collection/project to prevent this?

2 Replies

  • Unfortunately that there is no global toggle in Azure DevOps to prevent this but some workarounds like:

     

    Rename the YAML file, before cloning into the test instance, rename the file to something like

     

    azure-pipelines-test.yml

     

    • msherms's avatar
      msherms
      Copper Contributor

      Not really possible with an IT driven backup scenario. But also...why did they add a feature that's completely undocumented?? Is it documented somewhere else I haven't seen?

Resources