{CI} Update SBOM task conditions to trigger on release branches only#32008
{CI} Update SBOM task conditions to trigger on release branches only#32008wangzelin007 merged 3 commits intoAzure:devfrom
Conversation
️✔️AzureCLI-FullTest
|
️✔️AzureCLI-BreakingChangeTest
|
There was a problem hiding this comment.
Pull Request Overview
This PR updates the SBOM (Software Bill of Materials) task conditions in the Azure DevOps pipeline to support IndividualCI builds in addition to BatchedCI builds. The change addresses failures in recent pull requests where the SBOM task was running inappropriately in non-customer-facing builds.
- Replaces single equality condition checks with multi-value condition checks for SBOM tasks
- Adds IndividualCI trigger support for official CLI release builds
- Maintains existing BatchedCI support while expanding to IndividualCI scenarios
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
|
Thank you for your contribution! We will review the pull request and get back to you soon. |
|
The git hooks are available for azure-cli and azure-cli-extensions repos. They could help you run required checks before creating the PR. Please sync the latest code with latest dev branch (for azure-cli) or main branch (for azure-cli-extensions). pip install azdev --upgrade
azdev setup -c <your azure-cli repo path> -r <your azure-cli-extensions repo path>
|
|
|
|
Will enabling SBOM break our batched CI now? |
|
| displayName: 'SBOM' | ||
| condition: eq(variables['Build.Reason'], 'BatchedCI') | ||
| continueOnError: true | ||
| condition: startsWith(variables['Build.SourceBranch'], 'refs/heads/release') |
…zure#32008) (cherry picked from commit 008f1c2)
…zure#32008) (cherry picked from commit 008f1c2)
SBOM task

The SBOM task has consistently failed in recent pull requests, with the error shown in the screenshot below. According to the SBOM team, the SBOM task should not be used in non-customer-facing builds.
In #31994, we updated the task’s execution condition to BatchedCI which is incorrect.
This PR will update SBOM task conditions to trigger on release branches only, which is used during the official CLI release build.
Related command
Description
Testing Guide
History Notes
[Component Name 1] BREAKING CHANGE:
az command a: Make some customer-facing breaking change[Component Name 2]
az command b: Add some customer-facing featureThis checklist is used to make sure that common guidelines for a pull request are followed.
The PR title and description has followed the guideline in Submitting Pull Requests.
I adhere to the Command Guidelines.
I adhere to the Error Handling Guidelines.