Skip to content

Enable OneLoc GitHub App authentication outside internal - #17365

Merged
missymessa merged 2 commits into
mainfrom
missymessa/devdiv-oneloc-github-app
Aug 18, 2026
Merged

missymessa merged 2 commits into
mainfrom
missymessa/devdiv-oneloc-github-app

Conversation

@missymessa

Copy link
Copy Markdown
Member

Summary

  • add an explicit, default-off opt-in for OneLocBuild GitHub App authentication outside dnceng/internal
  • preserve the PAT fallback for every existing non-internal pipeline
  • document the project-scoped WIF service connection and signing-key requirements

Motivation

MSBuild localization runs in the DevDiv Azure DevOps project. Its OneLocBuild job currently falls back to the shared GitHub PAT even though a DevDiv-scoped, least-privilege WIF connection is now provisioned. This lets MSBuild opt into the short-lived GitHub App token without changing other DevDiv pipelines.

Validation

  • verified all existing default combinations retain their current App/PAT selection
  • minted a token with the shared App signing key and confirmed dotnet/msbuild is selected in the App installation
  • DevDiv service connection devdiv-oneloc-githubapp is scoped to the signing key and authorized only for MSBuild pipeline 9434

Add an explicit, default-off opt-in for projects with separately provisioned WIF service connections.

Co-authored-by: Copilot <[email protected]>

Copilot-Session: 80f6a0c6-7947-4200-bb78-7f0fc01d671a
Copilot AI lite review requested due to automatic review settings August 18, 2026 16:47
@missymessa
missymessa requested a review from mmitche August 18, 2026 16:48
@missymessa
missymessa enabled auto-merge (squash) August 18, 2026 16:48

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

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 extends the OneLocBuild pipeline template to allow explicit, default-off opt-in to GitHub App authentication outside the dnceng/internal Azure DevOps project, while preserving the existing PAT-based fallback behavior for all non-internal pipelines by default. It also updates documentation to explain the new opt-in and the required project-scoped service connection/signing-key access.

Changes:

  • Added UseGitHubAppAuthenticationInOtherProjects (default false) and updated template conditions so non-internal projects only use the GitHub App token path when explicitly opted in.
  • Preserved the PAT selection path for all existing/non-internal pipelines unless they opt in.
  • Updated OneLocBuild docs to describe the new opt-in parameter and the service connection / Key Vault signing requirements.

Reviewed changes

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

File Description
eng/common/core-templates/job/onelocbuild.yml Adds an explicit opt-in switch for GitHub App token minting outside dnceng/internal, while keeping existing defaults and PAT fallback behavior.
Documentation/OneLocBuildGitHubApp.md Documents the opt-in behavior and the requirements for project-scoped WIF service connections and signing-key access.
Documentation/OneLocBuild.md Updates the template parameter reference to include the new opt-in parameter and its requirements.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread Documentation/OneLocBuildGitHubApp.md Resolved
@missymessa
missymessa requested a review from ViktorHofer August 18, 2026 16:51
Co-authored-by: Copilot <[email protected]>

Copilot-Session: 80f6a0c6-7947-4200-bb78-7f0fc01d671a
Copilot AI review requested due to automatic review settings August 18, 2026 16:52

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

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

Suppressed comments (2)

Documentation/OneLocBuildGitHubApp.md:94

  • This paragraph is introducing the non-dnceng/internal opt-in, but it doesn’t explicitly tie back to the preceding “no authentication parameter is required” example, which can read as globally true. Add a short bridge sentence making it clear the prior example assumes dnceng/internal.
For a pipeline outside `dnceng/internal`, keep using the wrapper appropriate for that pipeline
(`templates/job` or `templates-official/job`) and explicitly select its project-scoped connection.
This example uses the official wrapper:

Documentation/OneLocBuildGitHubApp.md:27

  • The sentence says the App token is minted when “all” conditions are true, but the third bullet is an OR-condition. This reads contradictory and is easy to misinterpret; rephrase to keep the logic unambiguous (A && B && (C || D)).
when **all** of the following are true:

- `UseGitHubAppAuthentication` is `true` (the default), **and**
- `RepoType` is `gitHub`, **and**
- the build is running in the **`internal`** Azure DevOps project, or

@missymessa
missymessa merged commit 16008eb into main Aug 18, 2026
10 of 13 checks passed
@missymessa
missymessa deleted the missymessa/devdiv-oneloc-github-app branch August 18, 2026 18:30
@dotnet-milestone-bot dotnet-milestone-bot Bot added this to the 12.0-preview1 milestone Aug 19, 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