-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add article: Authenticate to third-party services #420
Draft
vicroms
wants to merge
1
commit into
microsoft:main
Choose a base branch
from
vicroms:auth
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
@@ -0,0 +1,90 @@ | ||||||
--- | ||||||
title: "Authenticate to third-party services" | ||||||
description: Explain different authentication methods to third-party services consumed by vcpkg | ||||||
author: vicroms | ||||||
ms.author: viromer | ||||||
ms.date: 10/31/2024 | ||||||
ms.topic: tutorial | ||||||
zone_pivot_group_filename: zone-pivot-groups.json | ||||||
zone_pivot_groups: shell-selections | ||||||
--- | ||||||
# Authenticate to third-party services | ||||||
|
||||||
vcpkg has features that leverage third-party services like Azure DevOps, Azure | ||||||
Containers, and other similar services, which require authentication to be used. | ||||||
This article lists authentication methods for these services that work with | ||||||
vcpkg. | ||||||
|
||||||
## Azure DevOps | ||||||
vcpkg can interact with AzureDevOps in multiple contexts: as a host for a source | ||||||
code repository, as a backend for binary caching, or running as part of an ADO | ||||||
pipeline. | ||||||
|
||||||
To methods described below for [authenticating to Git repositories](#git) and | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
[NuGet feeds](#nuget) apply for repositories and artifact feeds hosted in Azure | ||||||
DevOps. See the [tutorial for packaging an ADO | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think you should explain what ADO means. |
||||||
dependency](../produce/package-ado-dependency.md) or the [Test your custom | ||||||
registry ports using vcpkg with Azure | ||||||
DevOps](../produce/test-registry-ports-ado.md) for examples. | ||||||
|
||||||
Azure DevOps provides a non-NuGet based binary caching backend in the form of | ||||||
[Universal Packages](../reference/binarycaching.md#azuniversal). See the | ||||||
[Quickstart](../reference/binarycaching.md#azuniversal-quickstart) section for | ||||||
details on how to use and authenticate to this backend. | ||||||
|
||||||
The [Test your custom registry ports using vcpkg with Azure | ||||||
DevOps](../produce/test-registry-ports-ado.md) article contains multiple | ||||||
examples of authenticating to other services when vcpkg is running as part of an | ||||||
Azure DevOps pipeline job. | ||||||
|
||||||
## Azure Blob Storage | ||||||
vcpkg can use Azure Blob Storage as an asset caching backend. The | ||||||
authentication method requires providing a SAS token as part of the [asset cache | ||||||
configuration](../users/assetcaching.md#azurl). | ||||||
|
||||||
## Git | ||||||
To authenticate to a [private Git | ||||||
registry](../concepts/registries.md#git-registries) follow one of the methods in | ||||||
the [Authenticate to Git repositories](../users/authentication.md) article. | ||||||
|
||||||
If your [package's port](../concepts/ports.md) requires source code hosted in a | ||||||
private Git repository, we recommend to use the | ||||||
[`vcpkg_from_git`](../maintainers/functions/vcpkg_from_git.md) helper function | ||||||
and follow one of the methods in the [Authenticate to Git | ||||||
repositories](../users/authentication.md) article. Alternatively, but not | ||||||
recommended the | ||||||
[vcpkg_from_gitHub](../maintainers/functions//vcpkg_from_github.md#AUTHORIZATION_TOKEN) | ||||||
and | ||||||
[vcpkg_from_gitlab](../maintainers/functions/vcpkg_from_gitlab.md#AUTHORIZATION_TOKEN) | ||||||
provide an `AUTHORIZATION_TOKEN` parameter. | ||||||
|
||||||
Read the [Tutorial: Authenticate vcpkg Git-based registries in GitHub | ||||||
Actions](../consume/gha-authentication.md) article to learn how to authenticate | ||||||
to private Git repositories when running vcpkg in a GitHub Actions workflow. | ||||||
|
||||||
## GitHub Actions | ||||||
vcpkg can authenticate to GitHub Actions Cache to easily set up a [binary | ||||||
cache](../reference/binarycaching.md#github-actions-cache) when running in a | ||||||
GitHub Actions workflow. See the [Tutorial: Set up a vcpkg binary cache using | ||||||
GitHub Actions Cache](../consume/binary-caching-github-actions-cache.md) article | ||||||
for instructions and the [Test your custom registry ports using vcpkg with | ||||||
GitHub Actions](../produce/test-registry-ports-gha.md) for an example. | ||||||
|
||||||
You can also use [GitHub Packages](../reference/binarycaching.md#github-packages) | ||||||
as your binary caching backend. See the | ||||||
[Tutorial: Set up a vcpkg binary cache using GitHub Packages in a GitHub Actions | ||||||
workflow](../consume/binary-caching-github-packages.md) article for | ||||||
instructions. | ||||||
|
||||||
The [Test your custom registry ports using vcpkg with GitHub | ||||||
Actions](../produce/test-registry-ports-gha.md) article contains multiple | ||||||
examples of authenticating to other services when vcpkg is running as part of a | ||||||
GitHub Actions workflow. | ||||||
|
||||||
## NuGet | ||||||
To provide credentials for a NuGet feed used as a binary cache use one of the | ||||||
methods in the [Binary Caching | ||||||
configuration](../reference/binarycaching.md#nuget-credentials) article. See the | ||||||
[binary caching using a NuGet | ||||||
feed](../consume/binary-caching-nuget.md#provide-authentication-credentials) | ||||||
tutorial for an example. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This article uses multiple ways to spell Azure Devops.