You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(docs): add Google Artifact Registry index instructions
This commit adds Google Artifact Registry authentication instructions for both basic HTTP authentication and keyring methods.
Locally tested using both methods.
Authenticate to a repository using password authentication
70
+
or using [`keyring`](https://github.com/jaraco/keyring) package.
71
+
72
+
!!! note
73
+
74
+
This guide assumes `gcloud` CLI has previously been installed and setup.
75
+
76
+
### Password authentication
77
+
78
+
Credentials can be provided via "Basic" HTTP authentication scheme. Include access token in the password field of the URL. Username must be `oauth2accesstoken`, otherwise authentication will fail.
79
+
80
+
For example, with the token stored in the `$ARTIFACT_REGISTRY_TOKEN` environment variable, set the index URL with:
You can also authenticate to Artifact Registry using
90
+
[`keyring`](https://github.com/jaraco/keyring) package with
91
+
[`keyrings.google-artifactregistry-auth` plugin](https://github.com/GoogleCloudPlatform/artifact-registry-python-tools). Because these two
92
+
packages are required to authenticate to Artifact Registry, they must be pre-installed from a source
93
+
other than Artifact Registry.
94
+
95
+
The `artifacts-keyring` plugin wraps
96
+
[gcloud CLI](https://cloud.google.com/sdk/gcloud) to generate short-lived access tokens, securely store them in system keyring and refresh them when they are expired.
0 commit comments