Usually, I create a new build pipeline via the Azure DevOps portal. Then, the editor will take me through the steps of choosing the project source, repository, and template. After that, I will have an option to create a new branch or commit directly to the master branch.
However, this time, I have an existing azure-pipelines.yml
file in my branch. I created it with a text editor locally and push this branch to Azure DevOps. I want to attach this file and let Azure Pipelines create and queue a new build. But I can't find any option. The importing build pipeline option only accepts JSON files.
Is it possible to create a new build pipeline from an existing YML file in the repository?
I know I can use the classic editor, which has a step to specify a YML file. But I prefer an option that I can use the YML editor with Task Assistant on the Azure DevOps portal.
Thank you all.
Navigate to the pipeline details page for your pipeline. Choose ... and select Clone. Your pipeline is cloned with -clone appended to the name. Choose Save or Save & queue to save the cloned pipeline.
Sign in to your organization ( https://dev.azure.com/{yourorganization} ). Select your project, choose Pipelines > Pipelines, and then select the pipeline you want to edit. Choose Edit. Make edits to your pipeline using Intellisense keyboard shortcuts and the task assistant for guidance.
Sign-in to your Azure DevOps organization and go to your project. Go to Pipelines, and then select New pipeline. Do the steps of the wizard by first selecting GitHub as the location of your source code. You might be redirected to GitHub to sign in.
Sign in to your Azure DevOps organization and navigate to your project. In your project, go to the Pipelines page, and then select New pipeline. Select GitHub as the location of your source code. For Repository, select Authorize and then Authorize with OAuth.
If you pushed azure-pipelines.yml
to a new branch, Azure DevOps detect it automatically, if you have a CI trigger you will see a build start to running.
You can create a new pipeline and specify an existing YAML file:
-> Choose you repository.
You can also can go the repo build page (if you already have a build for this repo with other branch) and click Run pipeline and there choose the branch:
I found that the easiest method is to navigate to the Repos section, select the repository and click on the Set up Build button there.
You can then select Existing Azure Pipelines YAML file from the options.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With