Skip to content

Instantly share code, notes, and snippets.

@PadreSVK
Created May 19, 2021 16:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save PadreSVK/dd9a272005fd6bd96dc4d4b8d1e9c456 to your computer and use it in GitHub Desktop.
Save PadreSVK/dd9a272005fd6bd96dc4d4b8d1e9c456 to your computer and use it in GitHub Desktop.
Sample of multistage pipeline
trigger:
branches:
include:
- master
pool: "Default"
variables:
displayName: My Awesome project
csprojPath: MyProject.csproj
stages:
- stage: Build
jobs:
# build jobs
- stage: Test
dependsOn: Build
jobs:
# test jobs
- stage: Staging
dependsOn: Test
jobs:
# staging jobs
- stage: InternalDeploy
displayName: "[Internal] deploy"
dependsOn: Staging
jobs:
- deployment:
displayName: "Deploy XYZ"
environment:
name: Internal
strategy:
runOnce:
deploy:
steps:
- template: publish-template.yml
- stage: PoblicDeploy
displayName: "[Public] deploy"
dependsOn: Staging
jobs:
- deployment:
displayName: "Deploy XYZ"
environment:
name: Public
strategy:
runOnce:
deploy:
steps:
- template: publish-template.yml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment