Skip to content

Symbols Publishing Follow-up#4214

Merged
paulmedynski merged 3 commits intomainfrom
dev/paul/symbols-publishing-linux
Apr 21, 2026
Merged

Symbols Publishing Follow-up#4214
paulmedynski merged 3 commits intomainfrom
dev/paul/symbols-publishing-linux

Conversation

@paulmedynski
Copy link
Copy Markdown
Contributor

@paulmedynski paulmedynski commented Apr 20, 2026

Summary

Switches the OneBranch publish symbols jobs from Windows to Linux agents, fixes a cross-org authentication issue discovered during validation, and routes official symbols to PPE when releaseToProduction is false.

Follow-up to #4175.

Changes

Linux Pool for Symbols Jobs

  • Change pool.type from windows to linux in publish-symbols-job.yml.
  • Add LinuxContainerImage variable to onebranch-variables.yml.
  • Add .artifactignore step to suppress empty artifact auto-publishing on Linux.

Fix cross-org symbol upload authentication (VS30063)

  • Move ArtifactServices.Symbol.AccountName from a runtime ##vso[task.setvariable] step (which ran inside the build container) to a job-level variable.
  • Root cause: On OneBranch Linux agents, PublishSymbols@2 runs on the host agent (outside the build container) due to 1ES Pipeline Template credential isolation. The host defaults to the microsoft org, so $(System.AccessToken) (scoped to SqlClientDrivers) could not authenticate against https://microsoft.artifacts.visualstudio.com. Setting the variable at job scope makes it visible to both container and host steps, routing the upload to https://SqlClientDrivers.artifacts.visualstudio.com.
  • On Windows this was not an issue because the host agent was already in the SqlClientDrivers org context.

Route official symbols to PPE when releaseToProduction is false

  • The official pipeline's publishSymbols stage was hardcoded to the Production symbol server regardless of the releaseToProduction flag. This meant there was no way to do a full dry-run release targeting both NuGet Test and symbol server PPE.
  • Now releaseToProduction drives both destinations:
    • true → NuGet Production + Production symbol server
    • false → NuGet Test + PPE symbol server
  • The publishSymbols flag still independently controls whether symbols are published at all.
  • The non-official pipeline is unchanged (always PPE).

Testing

  • Non-official pipeline build 148586 failed with VssUnauthorizedException (VS30063) on Linux → root cause identified → fix applied → re-run expected to succeed.
  • TBD: Validate ESRP minimatch changes with an Official pipeline run (since ESRP tasks only execute in Official runs).

- Change pool type from windows to linux in publish-symbols-job.yml
- Add LinuxContainerImage variable to onebranch-variables.yml
- Add .artifactignore step to suppress empty artifact publishing
- Improve comments in publish-symbols-step.yml
PublishSymbols@2 runs on the OneBranch host agent (outside the build
container) due to 1ES PT credential isolation. The previous runtime
##vso[task.setvariable] ran inside the container and was not visible
to the host-level task. On Linux the host defaults to the Microsoft
org, causing a VssUnauthorizedException (VS30063).

Move ArtifactServices.Symbol.AccountName to a job-level variable so
it is visible to both container and host steps.
Copilot AI review requested due to automatic review settings April 20, 2026 13:19
@paulmedynski paulmedynski added this to the 7.1.0-preview1 milestone Apr 20, 2026
@paulmedynski paulmedynski added Area\Engineering Use this for issues that are targeted for changes in the 'eng' folder or build systems. Hotfix Candidate 🚑 Issues/PRs that are candidate for backporting to earlier supported versions. labels Apr 20, 2026
@paulmedynski paulmedynski moved this from To triage to In progress in SqlClient Board Apr 20, 2026
@github-project-automation github-project-automation Bot moved this to To triage in SqlClient Board Apr 20, 2026
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

This PR updates the OneBranch symbols publishing stage to run on Linux agents and adjusts symbol-upload configuration to work correctly under 1ES Pipeline Template host/container credential isolation.

Changes:

  • Switch publish-symbols-job.yml to a Linux pool and add a workaround to avoid publishing meaningful job artifacts.
  • Move ArtifactServices.Symbol.AccountName configuration to job scope (instead of setting it at runtime inside the container).
  • Add a Linux container image variable and update symbol-publish step comments accordingly.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
eng/pipelines/onebranch/variables/onebranch-variables.yml Adds LinuxContainerImage and clarifies container image variables.
eng/pipelines/onebranch/steps/publish-symbols-step.yml Removes runtime variable-setting step; documents why job-level scope is required.
eng/pipelines/onebranch/jobs/publish-symbols-job.yml Switches symbols publishing job to Linux; sets org-routing variable at job scope; adds .artifactignore generation to produce empty auto-published artifacts.

Comment thread eng/pipelines/onebranch/jobs/publish-symbols-job.yml
Comment thread eng/pipelines/onebranch/jobs/publish-symbols-job.yml
@paulmedynski paulmedynski marked this pull request as ready for review April 20, 2026 13:41
@paulmedynski paulmedynski requested a review from a team as a code owner April 20, 2026 13:41
@paulmedynski paulmedynski moved this from In progress to In review in SqlClient Board Apr 20, 2026
The official pipeline's publishSymbols stage was hardcoded to the
Production symbol server regardless of the releaseToProduction flag.
This meant there was no way to do a full dry-run release targeting
both NuGet Test and symbol server PPE.

Now the releaseToProduction parameter drives both destinations:
  true  → NuGet Production + Production symbol server
  false → NuGet Test + PPE symbol server

The publishSymbols flag still independently controls whether symbols
are published at all. The non-official pipeline is unchanged (always
PPE).
@paulmedynski paulmedynski changed the title Switch publish symbols jobs to Linux pool Symbols Publishing Follow-up Apr 20, 2026
Comment thread eng/pipelines/onebranch/jobs/publish-symbols-job.yml
Comment thread eng/pipelines/onebranch/variables/onebranch-variables.yml
Comment thread eng/pipelines/onebranch/sqlclient-official.yml
Comment thread eng/pipelines/onebranch/jobs/publish-symbols-job.yml
@paulmedynski paulmedynski merged commit 8d2483b into main Apr 21, 2026
8 checks passed
@paulmedynski paulmedynski deleted the dev/paul/symbols-publishing-linux branch April 21, 2026 10:36
@github-project-automation github-project-automation Bot moved this from In review to Done in SqlClient Board Apr 21, 2026
@paulmedynski paulmedynski added Hotfix 7.0.1 When this PR merges, automatically open a PR to cherry-pick to the 7.0.1 branch and removed Hotfix Candidate 🚑 Issues/PRs that are candidate for backporting to earlier supported versions. labels Apr 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area\Engineering Use this for issues that are targeted for changes in the 'eng' folder or build systems. Hotfix 7.0.1 When this PR merges, automatically open a PR to cherry-pick to the 7.0.1 branch

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

4 participants