Microsoft DevOps Engineer Expert AZ-400 Practice Question
You are creating an Azure Pipelines YAML file for a mono-repository that contains dozens of feature branches. Your goals are:
A continuous integration (CI) build must trigger automatically for commits pushed directly to the main branch and any release/* branches.
Commits pushed to feature branches must not start a CI build unless the branch is the source of a pull request (PR) that targets main or a release/* branch.
If a developer's commit message contains the text "[skip ci]" or "[ci skip]", the build must be skipped.
Which YAML configuration satisfies all the requirements?
trigger: none
pr:
branches:
include:
- main
- release/*
trigger:
branches:
include:
- main
- release/*
- feature/*
pr:
branches:
include:
- main
- release/*
trigger:
branches:
include:
- *
pr: none
trigger:
branches:
include:
- main
- release/*
pr:
branches:
include:
- main
- release/*
The CI requirements are met by explicitly listing main and release/* in the CI trigger's include filter, so pushes to other branches (for example, feature branches) do not start a build. A separate pr section is required because PR triggers are evaluated independently of CI triggers; listing the same target branches in pr ensures that builds run when a feature branch is opened as a pull request to main or a release/* branch. Azure Pipelines automatically honours the strings [skip ci] or [ci skip] in the commit message, so no additional YAML is needed for requirement 3. Options that either include feature/* in the CI filter, disable the pr trigger, or set trigger: none fail to meet one or more stated requirements.
Ask Bash
Bash is our AI bot, trained to help you pass your exam. AI Generated Content may display inaccurate information, always double-check anything important.
What is the difference between 'trigger' and 'pr' in Azure Pipelines YAML file?
Open an interactive chat with Bash
How do commit message strings like '[skip ci]' work in Azure Pipelines?
Open an interactive chat with Bash
What is the significance of 'release/*' in the branch filter configuration?
Open an interactive chat with Bash
Microsoft DevOps Engineer Expert AZ-400
Design and implement build and release pipelines
Your Score:
Report Issue
Bash, the Crucial Exams Chat Bot
AI Bot
Loading...
Loading...
Loading...
Pass with Confidence.
IT & Cybersecurity Package
You have hit the limits of our free tier, become a Premium Member today for unlimited access.
Military, Healthcare worker, Gov. employee or Teacher? See if you qualify for a Community Discount.
Monthly
$19.99
$19.99/mo
Billed monthly, Cancel any time.
3 Month Pass
$44.99
$14.99/mo
One time purchase of $44.99, Does not auto-renew.
MOST POPULAR
Annual Pass
$119.99
$9.99/mo
One time purchase of $119.99, Does not auto-renew.
BEST DEAL
Lifetime Pass
$189.99
One time purchase, Good for life.
What You Get
All IT & Cybersecurity Package plans include the following perks and exams .