Questions tagged [azure-pipelines-yaml]

Azure Pipelines automatically builds and tests code projects to make them available to others. It works with just about any language or project type. Azure Pipelines combines continuous integration (CI) and continuous delivery (CD) to test and build your code and ship it to any target. YAML (or YML) is the language used to construct pipeline objects.

1379 questions
17
votes
6 answers

"Configuring the trigger failed, edit and save the pipeline again" with no noticeable error and no further details

I have run in to an odd problem after converting a bunch of my YAML pipelines to use templates for holding job logic as well as for defining my pipeline variables. The pipelines run perfectly fine, however I get a "Some recent issues detected…
13
votes
1 answer

How to change the repository location for a pipeline in Azure Pipelines

I have imported a repository from BitBucket to GitHub. How can I point the existing pipeline in Azure Pipelines to the new repository location? The UI has failed me so far.
Ola Eldøy
  • 5,720
  • 7
  • 49
  • 82
12
votes
1 answer

How to automatically 'git tag -a' after a pull request has completed on Azure Devops?

How do we add custom annotated tags on master once the pull requests (PR) is complete, automatically? More background: Using azure-pipelines.yml Branch policies on master to force PR to be used We have a repository that holds Azure Devops Pipeline…
Adrian Torrie
  • 2,795
  • 3
  • 40
  • 61
11
votes
1 answer

How to force an Azure DevOps pipeline to fail if any previous tasks have failed?

My YAML-based Azure DevOps pipeline contains several tasks in which continueOnError: true. I did this deliberately so that I can run all test suites even when some of them fail (each task runs a different suite of tests). At the moment the build is…
11
votes
2 answers

Error: Unable to locate executable file: 'powershell' when running Azure CLI task in ADO pipeline

I am trying to run an Azure CLI task in pipeline and getting the following error : Starting: AzureCLI ============================================================================== Task : Azure CLI Description : Run Azure CLI commands…
Nilotpal
  • 3,237
  • 4
  • 34
  • 56
11
votes
1 answer

How to demand multiple agent machines in Azure devops pipeline pool?

I'm looking if I can specify a list of agents in Agent pool demands? In UI azure pipeline has only two options equals and exists. So, I tried adding two demands but pipeline takes only first demand The same in yaml is as follows, pool: name: AWS…
r0r0n0a
  • 173
  • 2
  • 2
  • 10
11
votes
2 answers

Error Unexpected value 'steps' in azure-pipelines.yml

I am trying to copy a video file from GPM to app/dist/asset/images folder before building and deploying docker image.Getting Unexpected value 'Steps' at line 27. YML file works fine if I remove the step to copy the video file. azure-pipelines.yml …
Jan69
  • 1,109
  • 5
  • 25
  • 48
10
votes
1 answer

How can I get the current date in an Azure Pipeline YAML file to use ase a variable?

I'm trying to inject a useful version number into my ASP Core application which I'm building and deploying using an Azure DevOps pipeline. - script: dotnet publish -c $(buildConfiguration) -p:Version=2022.06.21…
Neutrino
  • 8,496
  • 4
  • 57
  • 83
10
votes
2 answers

How to work with DependsOn having stage dependency in Azure DevOps

I have below template which does multi stage deployment: parameters: - name: Stage type: string - name: Environment type: string - name: Enabled type: boolean default: false - name: WebAppName type: string - name: ArtifactName type:…
VR1256
  • 1,266
  • 4
  • 28
  • 56
10
votes
2 answers

Howto: Insert a template conditionally in Azure DevOps YAML?

Here's how I'm trying to accomplish inserting a template conditionally. Per requirement, I would like to either call fresh-deploy.yml or update.yml based on a pipeline variable supplied at run time. The user can edit a variable called…
Vyas Bharghava
  • 6,372
  • 9
  • 39
  • 59
10
votes
1 answer

Cancel previous release azure pipeline yaml

When creating a release pipeline via the UI (Release) in Azure Devops you have the option cancel previous release. How can i create this with YAML in my release pipeline, now as you can see al the previous releases are still waiting
9
votes
2 answers

How to delete an Azure Pipeline cache without changing cache key

I have a task that creates a cache - task: Cache@2 inputs: key: 'sonarCache' path: $(SONAR_CACHE) cacheHitVar: CACHE_RESTORED displayName: Cache Sonar packages However, the cache got corrupted. So how do I run this pipeline while…
TSR
  • 17,242
  • 27
  • 93
  • 197
9
votes
2 answers

ERROR: The requested resource requires user authentication: in AzureCLI task build pipeline

I am unable to trigger azure pipeline build from azureCLI task Task : - task: AzureCLI@2 inputs: azureSubscription: 'Free Trial(My subscription)' scriptType: 'pscore' scriptLocation: 'inlineScript' inlineScript: | az…
9
votes
1 answer

DevOps CICD - Parallel stages Deployment

I have a new release pipeline contains 75 stages, when I create release each one of the stages take in average 5 minutes to complete deployment process then move to next one, that mean I need almost 7 hours to deploy all stages. How can I make all…
9
votes
2 answers

Changing the working directory for all steps in Azure Pipelines YAML

It's possible to set the working directory for separate scripts: - script: foo workingDirectory: bar However, if all the steps are meant to run in a specific directory, it becomes repetitive to define it for each step. Using cd doesn't affect…
slikts
  • 8,020
  • 1
  • 27
  • 47
1
2
3
91 92