Skip to content

Hardcode Official templates#26928

Open
jshigetomi wants to merge 2 commits intoPowerShell:masterfrom
jshigetomi:hardCodeTemplate
Open

Hardcode Official templates#26928
jshigetomi wants to merge 2 commits intoPowerShell:masterfrom
jshigetomi:hardCodeTemplate

Conversation

@jshigetomi
Copy link
Collaborator

@jshigetomi jshigetomi commented Mar 2, 2026

PR Summary

This pull request simplifies and standardizes the build pipeline YAML files by removing the OfficialBuild parameter and related conditional logic. All pipelines are now hardcoded to use the "official" build templates and settings, reducing complexity and potential for misconfiguration between official and non-official builds.

Key changes include:

Pipeline Parameter and Variable Simplification

  • Removed the OfficialBuild parameter from all relevant pipeline YAML files, eliminating conditional logic that switched between official and non-official templates and settings. Pipeline names and variables that previously referenced OfficialBuild are now hardcoded to use true or official values. [1] [2] [3] [4] [5] [6]

Template Usage Standardization

  • All pipelines now directly reference the official OneBranch templates (e.g., v2/OneBranch.Official.CrossPlat.yml@onebranchTemplates, v2/Microsoft.Official.yml@onebranchTemplates) instead of selecting a template based on the OfficialBuild parameter or a variable. [1] [2] [3] [4] [5] [6] [7] [8] [9]

Consistent Build Naming

  • Pipeline and build names that previously included the value of OfficialBuild now use true directly, ensuring consistent naming conventions across all official builds. [1] [2] [3] [4] [5]

Environment and Variable Hardcoding

  • Variables that previously depended on OfficialBuild (e.g., ps_official_build, releaseEnvironment) are now set to their official values unconditionally, further reducing conditional complexity. [1] [2]

These changes make the build pipelines easier to maintain by enforcing a single, official build path and removing unnecessary parameters and branching logic.

PR Context

This is necessary to comply with 1ES Drift Management policy.

PR Checklist

@jshigetomi jshigetomi marked this pull request as ready for review March 2, 2026 20:29
@jshigetomi jshigetomi requested a review from a team as a code owner March 2, 2026 20:29
Copilot AI review requested due to automatic review settings March 2, 2026 20:29
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR removes the OfficialBuild parameter and related conditional logic from several Azure DevOps pipeline YAMLs, hardcoding them to use OneBranch “Official” templates/settings to reduce drift and configuration complexity.

Changes:

  • Removed the OfficialBuild queue-time parameter from multiple “Official” pipelines and simplified dependent variables.
  • Hardcoded extends.template to official OneBranch governed templates instead of selecting official/non-official at runtime.
  • Standardized build naming to always reflect the official path (prod.true).

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
.pipelines/PowerShell-vPack-Official.yml Removes OfficialBuild parameter and hardcodes use of v2/Microsoft.Official.yml template.
.pipelines/PowerShell-Release-Official.yml Removes OfficialBuild parameter, hardcodes Production environment and official CrossPlat template.
.pipelines/PowerShell-Release-Official-Azure.yml Removes OfficialBuild parameter and hardcodes official CrossPlat template.
.pipelines/PowerShell-Packages-Official.yml Removes OfficialBuild parameter and hardcodes official CrossPlat template (but leaves a broken reference—see PR comments).
.pipelines/PowerShell-Coordinated_Packages-Official.yml Removes OfficialBuild parameter, hardcodes official CrossPlat template, and sets ps_official_build to true.

@jshigetomi jshigetomi added the CL-BuildPackaging Indicates that a PR should be marked as a build or packaging change in the Change Log label Mar 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

BackPort-7.4.x-Consider BackPort-7.5.x-Consider BackPort-7.6.x-Consider CL-BuildPackaging Indicates that a PR should be marked as a build or packaging change in the Change Log

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants