Ensure Automatic Build for Azure DevOps Project

After Stage

Question

Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.

After you answer a question in this section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen.

Your company has a project in Azure DevOps for a new web application.

You need to ensure that when code is checked in, a build runs automatically.

Solution: From the Pre-deployment conditions settings of the release pipeline, you select After stage.

Does this meet the goal?

Answers

Explanations

Click on the arrows to vote for the correct answer

A. B.

B

Instead, In Visual Designer you enable continuous integration (CI) by:

1. Select the Triggers tab.

2. Enable Continuous integration.

https://docs.microsoft.com/en-us/azure/devops/pipelines/get-started-designer

The given solution of selecting "After stage" from the Pre-deployment conditions settings of the release pipeline does not meet the goal of ensuring that when code is checked in, a build runs automatically.

The Pre-deployment conditions settings of a release pipeline define the conditions that must be met before the release is deployed to the target environment. The "After stage" option in these settings means that the release will run automatically after a specific stage in the pipeline has completed, but it does not trigger a build when code is checked in.

To ensure that a build runs automatically when code is checked in, you need to set up a Continuous Integration (CI) pipeline in Azure DevOps. A CI pipeline automatically builds and tests code every time it is checked in to the version control system, such as Git or Azure Repos.

To set up a CI pipeline in Azure DevOps, you can create a new pipeline and select the appropriate repository and branch to build. Then, you can configure the build steps, such as defining the build agent, selecting the build environment, specifying the build tools and commands, and setting up any required dependencies or configurations. Once the pipeline is created and configured, it will automatically trigger a build every time code is checked in to the selected branch.

In summary, the given solution of selecting "After stage" from the Pre-deployment conditions settings of the release pipeline does not meet the goal of ensuring that when code is checked in, a build runs automatically. To achieve this goal, a Continuous Integration (CI) pipeline needs to be set up in Azure DevOps, which automatically builds and tests code every time it is checked in to the version control system.