Skip to content

Remove symbol server PATs from release/9.0 publish.yml#16895

Closed
missymessa wants to merge 2 commits into
release/9.0from
dev/mjanecke/remove-symbol-pats-9.0
Closed

Remove symbol server PATs from release/9.0 publish.yml#16895
missymessa wants to merge 2 commits into
release/9.0from
dev/mjanecke/remove-symbol-pats-9.0

Conversation

@missymessa
Copy link
Copy Markdown
Member

Summary

Removes microsoft-symbol-server-pat and symweb-symbol-server-pat from the release/9.0 publish pipeline by replacing them with an Entra bearer token from the maestro-build-promotion service connection.

Approach

  1. New step Get Symbol Server Token - Uses AzureCLI@2 with maestro-build-promotion SC to acquire a bearer token for the AzDO resource scope (499b84ac-1321-427f-aa17-267ca6975798)
  2. Replace PAT references - /p:MsdlToken and /p:SymWebToken now reference the bearer token output variable instead of the PAT variables
  3. Remove DotNet-Symbol-Server-Pats variable group - No longer needed

Why this works

symbol.exe (used by PublishSymbolsHelper.PublishAsync) accepts both PATs and Entra bearer tokens via the AzureDevOpsToken env var. The maestro-build-promotion identity already successfully publishes symbols to MSDL and SymWeb on main.

Context

Part of the PAT-to-Entra migration for WI 10149 (symweb-symbol-server-pat) and WI 10148 (microsoft-symbol-server-pat). The main branch migration was completed in PR #16808 (merged May 12). For this servicing branch, the YAML-only approach avoids risky C# code changes.

Risk and Rollback

If maestro-build-promotion lacks permissions to a specific symbol server, symbol publishing will fail. Revert this PR to restore PAT usage.

Related: https://dev.azure.com/dnceng/internal/_workitems/edit/10149

Replace microsoft-symbol-server-pat and symweb-symbol-server-pat with a
bearer token acquired from the maestro-build-promotion service connection
identity. symbol.exe accepts bearer tokens, so no C# code changes needed.

This removes the dependency on the DotNet-Symbol-Server-Pats variable group
for this branch, allowing the PATs to be decommissioned.
Copilot AI review requested due to automatic review settings May 26, 2026 22:58
Copy link
Copy Markdown
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

Updates the release/9.0 v3 publishing pipeline to stop using symbol server PATs and instead acquire an Entra (AAD) bearer token from the maestro-build-promotion service connection for publishing to MSDL and SymWeb.

Changes:

  • Removed the DotNet-Symbol-Server-Pats variable group from the publish stage.
  • Added an AzureCLI step to acquire an Azure DevOps resource access token (499b84ac-1321-427f-aa17-267ca6975798) and store it as a secret output variable.
  • Switched /p:MsdlToken and /p:SymWebToken to use the acquired bearer token.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 124 to +127
/p:SymbolPublishingExclusionsFile='$(Build.ArtifactStagingDirectory)/ReleaseConfigs/SymbolPublishingExclusionsFile.txt'
${{ parameters.symbolPublishingAdditionalParameters}}
/p:MsdlToken=$(microsoft-symbol-server-pat)
/p:SymWebToken=$(symweb-symbol-server-pat)
/p:MsdlToken=$(GetSymbolToken.SymbolServerToken)
/p:SymWebToken=$(GetSymbolToken.SymbolServerToken)
Comment on lines +93 to +95
inlineScript: |
$token = (az account get-access-token --resource "499b84ac-1321-427f-aa17-267ca6975798" --query accessToken -o tsv)
echo "##vso[task.setvariable variable=SymbolServerToken;isOutput=true;isSecret=true]$token"
@mmitche
Copy link
Copy Markdown
Member

mmitche commented May 27, 2026

Unnecessary. This YAML isn't used.

@mmitche
Copy link
Copy Markdown
Member

mmitche commented May 28, 2026

I think for 9.0, the real reference is coming from the eng/common/core-templates/steps/publish-logs.yml reference. It's not active, but would show up in the YAML.

@missymessa missymessa closed this May 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants