skip to Main Content

During continuous Deoloyment, Azure DevOps >> Pipelines >> Releases.
There are two parts, Artifacts and Stages.
Why do we need to setup a build pipeline and then specify a Git later?

Could anyone explain me why do I need this before Stages?


update: Build Yaml file:

trigger:
- production

pool:
  vmImage: ubuntu-latest

resources:
  repositories:
  - repository: repos
    type: git
    name: repos-name
    ref: refs/heads/production

steps:
  - checkout: repos
  - task: Synapse workspace deployment@2
    displayName: Validate Synapse workspace Artifacts
    inputs:
      operation: 'validate'
      ArtifactsFolder: '$(System.DefaultWorkingDirectory)'
      ResourceGroupName: 'resource'
      TargetWorkspaceName: 'workspace'
      DeleteArtifactsNotInTemplate: true

  - publish: $(System.DefaultWorkingDirectory)/ExportedArtifacts
    artifact: SynapseArtifact

2

Answers


  1. There are different types of artifact sources in Release pipelines, you can choose the one(s) that suits best your needs:

    Release pipeline - Add an artifact

    The most common artifact source is a build (aka Azure pipeline) – for example, if you have a build that produces artifacts (e.g. a .NET deployment package) that are required by the release pipeline.

    Azure Repos, Github, TFVC can be used when you want to consume artifacts directly from different source controls without passing them through a build pipeline.

    Please refer to Artifact sources in Classic release pipelines for more details.

    Login or Signup to reply.
  2. Why do we need to setup a build pipeline and then specify a Git later

    It is not mandatory to add both the build and the git repo as artifacts. You can choose the appropriate artifact according to your actual situation.

    According to the screenshots you provided, suppose you use the build pipeline to build a dedicated SQL pool and generate a DACPAC file, then deploy the SQL pool to Prod through the classic release pipeline; at the same time, you use the ARM template in the Azure repo to deploy the Azure Synapse workspace to Prod. The deployment of the dedicated SQL pool and Synapse workspace can be placed in two separate release pipelines or in one. Which resources to add as artifacts depends on your actual situation, and there is no single standard.


    Update

    According to your YAML and screenshots, your build pipeline is used to validate the Synapse artifacts and will trigger the release pipeline when the validation is passed. Then the release pipeline will deploy your ASA workspace automatically to Prod.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search