mirror of
https://github.com/docker/login-action.git
synced 2026-05-28 08:08:21 +01:00
Compare commits
2 Commits
dependabot
...
dependabot
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
93c0d7852b | ||
|
|
0750140bc8 |
4
.github/workflows/ci.yml
vendored
4
.github/workflows/ci.yml
vendored
@@ -150,7 +150,7 @@ jobs:
|
||||
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||
-
|
||||
name: Configure AWS Credentials
|
||||
uses: aws-actions/configure-aws-credentials@acca2b1b2070338fb9fd1ca27ecee81d687e58e5 # v6.1.2
|
||||
uses: aws-actions/configure-aws-credentials@d979d5b3a71173a29b74b5b88418bfda9437d885 # v6.1.1
|
||||
with:
|
||||
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
|
||||
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
|
||||
@@ -198,7 +198,7 @@ jobs:
|
||||
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||
-
|
||||
name: Configure AWS Credentials
|
||||
uses: aws-actions/configure-aws-credentials@acca2b1b2070338fb9fd1ca27ecee81d687e58e5 # v6.1.2
|
||||
uses: aws-actions/configure-aws-credentials@d979d5b3a71173a29b74b5b88418bfda9437d885 # v6.1.1
|
||||
with:
|
||||
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
|
||||
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
|
||||
|
||||
4
.github/workflows/codeql.yml
vendored
4
.github/workflows/codeql.yml
vendored
@@ -35,12 +35,12 @@ jobs:
|
||||
node-version: ${{ env.NODE_VERSION }}
|
||||
-
|
||||
name: Initialize CodeQL
|
||||
uses: github/codeql-action/init@7211b7c8077ea37d8641b6271f6a365a22a5fbfa # v4.36.0
|
||||
uses: github/codeql-action/init@9e0d7b8d25671d64c341c19c0152d693099fb5ba # v4.35.5
|
||||
with:
|
||||
languages: javascript-typescript
|
||||
build-mode: none
|
||||
-
|
||||
name: Perform CodeQL Analysis
|
||||
uses: github/codeql-action/analyze@7211b7c8077ea37d8641b6271f6a365a22a5fbfa # v4.36.0
|
||||
uses: github/codeql-action/analyze@9e0d7b8d25671d64c341c19c0152d693099fb5ba # v4.35.5
|
||||
with:
|
||||
category: "/language:javascript-typescript"
|
||||
|
||||
2
.github/workflows/test.yml
vendored
2
.github/workflows/test.yml
vendored
@@ -23,7 +23,7 @@ jobs:
|
||||
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||
-
|
||||
name: Test
|
||||
uses: docker/bake-action@6614cfa25eff9a0b2b2697efb0b6159e7680d584 # v7.2.0
|
||||
uses: docker/bake-action@a66e1c87e2eca0503c343edf1d208c716d54b8a8 # v7.1.0
|
||||
with:
|
||||
source: .
|
||||
targets: test
|
||||
|
||||
2
.github/workflows/update-dist.yml
vendored
2
.github/workflows/update-dist.yml
vendored
@@ -37,7 +37,7 @@ jobs:
|
||||
token: ${{ steps.docker-read-app.outputs.token }}
|
||||
-
|
||||
name: Build
|
||||
uses: docker/bake-action@6614cfa25eff9a0b2b2697efb0b6159e7680d584 # v7.2.0
|
||||
uses: docker/bake-action@a66e1c87e2eca0503c343edf1d208c716d54b8a8 # v7.1.0
|
||||
with:
|
||||
source: .
|
||||
targets: build
|
||||
|
||||
4
.github/workflows/validate.yml
vendored
4
.github/workflows/validate.yml
vendored
@@ -26,7 +26,7 @@ jobs:
|
||||
-
|
||||
name: Generate matrix
|
||||
id: generate
|
||||
uses: docker/bake-action/subaction/matrix@6614cfa25eff9a0b2b2697efb0b6159e7680d584 # v7.2.0
|
||||
uses: docker/bake-action/subaction/matrix@a66e1c87e2eca0503c343edf1d208c716d54b8a8 # v7.1.0
|
||||
with:
|
||||
target: validate
|
||||
|
||||
@@ -41,6 +41,6 @@ jobs:
|
||||
steps:
|
||||
-
|
||||
name: Validate
|
||||
uses: docker/bake-action@6614cfa25eff9a0b2b2697efb0b6159e7680d584 # v7.2.0
|
||||
uses: docker/bake-action@a66e1c87e2eca0503c343edf1d208c716d54b8a8 # v7.1.0
|
||||
with:
|
||||
targets: ${{ matrix.target }}
|
||||
|
||||
73
README.md
73
README.md
@@ -117,8 +117,6 @@ instead of a password.
|
||||
|
||||
### Azure Container Registry (ACR)
|
||||
|
||||
#### Service principal
|
||||
|
||||
[Create a service principal](https://docs.microsoft.com/en-us/azure/container-registry/container-registry-auth-service-principal#create-a-service-principal)
|
||||
with access to your container registry through the [Azure CLI](https://docs.microsoft.com/en-us/cli/azure/install-azure-cli)
|
||||
and take note of the generated service principal's ID (also called _client ID_)
|
||||
@@ -144,60 +142,10 @@ jobs:
|
||||
password: ${{ secrets.AZURE_CLIENT_SECRET }}
|
||||
```
|
||||
|
||||
> [!NOTE]
|
||||
> Replace `<registry-name>` with the name of your registry.
|
||||
|
||||
#### OpenID Connect (OIDC)
|
||||
|
||||
To authenticate with OpenID Connect, configure a federated identity credential
|
||||
for GitHub Actions and use the [Azure Login](https://github.com/Azure/login)
|
||||
action to sign in to Azure. Then expose an ACR access token and pass it to this
|
||||
action as the password.
|
||||
|
||||
```yaml
|
||||
name: ci
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: main
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
id-token: write
|
||||
|
||||
jobs:
|
||||
login:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
-
|
||||
name: Login to Azure
|
||||
uses: azure/login@v3
|
||||
with:
|
||||
client-id: ${{ vars.AZURE_CLIENT_ID }}
|
||||
tenant-id: ${{ vars.AZURE_TENANT_ID }}
|
||||
subscription-id: ${{ vars.AZURE_SUBSCRIPTION_ID }}
|
||||
-
|
||||
name: Get ACR access token
|
||||
id: acr-token
|
||||
run: |
|
||||
ACR_TOKEN=$(az acr login --name <registry-name> --expose-token --output tsv --query accessToken)
|
||||
echo "::add-mask::$ACR_TOKEN" # mask the token in workflow logs
|
||||
echo "token=$ACR_TOKEN" >> "$GITHUB_OUTPUT"
|
||||
-
|
||||
name: Login to ACR
|
||||
uses: docker/login-action@v4
|
||||
with:
|
||||
registry: <registry-name>.azurecr.io
|
||||
username: 00000000-0000-0000-0000-000000000000
|
||||
password: ${{ steps.acr-token.outputs.token }}
|
||||
```
|
||||
|
||||
> [!NOTE]
|
||||
> Replace `<registry-name>` with the name of your registry.
|
||||
|
||||
### Google Container Registry (GCR)
|
||||
|
||||
> [!NOTE]
|
||||
> [Google Artifact Registry](#google-artifact-registry-gar) is the evolution of
|
||||
> Google Container Registry. As a fully-managed service with support for both
|
||||
> container images and non-container artifacts. If you currently use Google
|
||||
@@ -228,7 +176,7 @@ jobs:
|
||||
-
|
||||
name: Authenticate to Google Cloud
|
||||
id: auth
|
||||
uses: google-github-actions/auth@v3
|
||||
uses: google-github-actions/auth@v1
|
||||
with:
|
||||
token_format: access_token
|
||||
workload_identity_provider: <workload_identity_provider>
|
||||
@@ -242,10 +190,9 @@ jobs:
|
||||
password: ${{ steps.auth.outputs.access_token }}
|
||||
```
|
||||
|
||||
> [!NOTE]
|
||||
> Replace `<workload_identity_provider>` with configured workload identity
|
||||
> provider. For steps to configure, [see here](https://github.com/google-github-actions/auth#setting-up-workload-identity-federation).
|
||||
>
|
||||
|
||||
> Replace `<service_account>` with configured service account in workload
|
||||
> identity provider which has access to push to GCR
|
||||
|
||||
@@ -300,7 +247,7 @@ jobs:
|
||||
-
|
||||
name: Authenticate to Google Cloud
|
||||
id: auth
|
||||
uses: google-github-actions/auth@v3
|
||||
uses: google-github-actions/auth@v1
|
||||
with:
|
||||
token_format: access_token
|
||||
workload_identity_provider: <workload_identity_provider>
|
||||
@@ -314,13 +261,12 @@ jobs:
|
||||
password: ${{ steps.auth.outputs.access_token }}
|
||||
```
|
||||
|
||||
> [!NOTE]
|
||||
> Replace `<workload_identity_provider>` with configured workload identity
|
||||
> provider
|
||||
>
|
||||
|
||||
> Replace `<service_account>` with configured service account in workload
|
||||
> identity provider which has access to push to GCR
|
||||
>
|
||||
|
||||
> Replace `<location>` with the regional or multi-regional [location](https://cloud.google.com/artifact-registry/docs/repo-organize#locations)
|
||||
> of the repository where the image is stored.
|
||||
|
||||
@@ -352,7 +298,6 @@ jobs:
|
||||
password: ${{ secrets.GAR_JSON_KEY }}
|
||||
```
|
||||
|
||||
> [!NOTE]
|
||||
> Replace `<location>` with the regional or multi-regional [location](https://cloud.google.com/artifact-registry/docs/repo-organize#locations)
|
||||
> of the repository where the image is stored.
|
||||
|
||||
@@ -407,7 +352,6 @@ jobs:
|
||||
AWS_ACCOUNT_IDS: 012345678910,023456789012
|
||||
```
|
||||
|
||||
> [!NOTE]
|
||||
> Only available with [AWS CLI version 1](https://docs.aws.amazon.com/cli/latest/reference/ecr/get-login.html)
|
||||
|
||||
You can also use the [Configure AWS Credentials](https://github.com/aws-actions/configure-aws-credentials)
|
||||
@@ -426,7 +370,7 @@ jobs:
|
||||
steps:
|
||||
-
|
||||
name: Configure AWS Credentials
|
||||
uses: aws-actions/configure-aws-credentials@v6
|
||||
uses: aws-actions/configure-aws-credentials@v4
|
||||
with:
|
||||
aws-access-key-id: ${{ vars.AWS_ACCESS_KEY_ID }}
|
||||
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
|
||||
@@ -438,7 +382,6 @@ jobs:
|
||||
registry: <aws-account-number>.dkr.ecr.<region>.amazonaws.com
|
||||
```
|
||||
|
||||
> [!NOTE]
|
||||
> Replace `<aws-account-number>` and `<region>` with their respective values.
|
||||
|
||||
### AWS Public Elastic Container Registry (ECR)
|
||||
@@ -470,7 +413,6 @@ jobs:
|
||||
AWS_REGION: <region>
|
||||
```
|
||||
|
||||
> [!NOTE]
|
||||
> Replace `<region>` with its respective value (default `us-east-1`).
|
||||
|
||||
### OCI Oracle Cloud Infrastructure Registry (OCIR)
|
||||
@@ -503,7 +445,6 @@ jobs:
|
||||
password: ${{ secrets.OCI_TOKEN }}
|
||||
```
|
||||
|
||||
> [!NOTE]
|
||||
> Replace `<region>` with their respective values from [availability regions](https://docs.cloud.oracle.com/iaas/Content/Registry/Concepts/registryprerequisites.htm#Availab)
|
||||
|
||||
### Quay.io
|
||||
@@ -662,7 +603,7 @@ jobs:
|
||||
scope: 'myorg/myimage@push'
|
||||
-
|
||||
name: Build and push
|
||||
uses: docker/build-push-action@v7
|
||||
uses: docker/build-push-action@v6
|
||||
with:
|
||||
push: true
|
||||
tags: myorg/myimage:latest
|
||||
|
||||
4
dist/index.cjs
generated
vendored
4
dist/index.cjs
generated
vendored
File diff suppressed because one or more lines are too long
2
dist/index.cjs.map
generated
vendored
2
dist/index.cjs.map
generated
vendored
File diff suppressed because one or more lines are too long
4
dist/licenses.txt
generated
vendored
4
dist/licenses.txt
generated
vendored
@@ -2337,8 +2337,8 @@ Apache License
|
||||
|
||||
The following npm packages may be included in this product:
|
||||
|
||||
- @aws-sdk/client-ecr-public@3.1052.0
|
||||
- @aws-sdk/client-ecr@3.1052.0
|
||||
- @aws-sdk/client-ecr-public@3.1053.0
|
||||
- @aws-sdk/client-ecr@3.1053.0
|
||||
|
||||
These packages each contain the following license:
|
||||
|
||||
|
||||
@@ -24,8 +24,8 @@
|
||||
"packageManager": "yarn@4.9.2",
|
||||
"dependencies": {
|
||||
"@actions/core": "^3.0.1",
|
||||
"@aws-sdk/client-ecr": "^3.1050.0",
|
||||
"@aws-sdk/client-ecr-public": "^3.1050.0",
|
||||
"@aws-sdk/client-ecr": "^3.1053.0",
|
||||
"@aws-sdk/client-ecr-public": "^3.1053.0",
|
||||
"@docker/actions-toolkit": "^0.90.0",
|
||||
"http-proxy-agent": "^9.0.0",
|
||||
"https-proxy-agent": "^9.0.0",
|
||||
|
||||
20
yarn.lock
20
yarn.lock
@@ -227,9 +227,9 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@aws-sdk/client-ecr-public@npm:^3.1050.0":
|
||||
version: 3.1052.0
|
||||
resolution: "@aws-sdk/client-ecr-public@npm:3.1052.0"
|
||||
"@aws-sdk/client-ecr-public@npm:^3.1053.0":
|
||||
version: 3.1053.0
|
||||
resolution: "@aws-sdk/client-ecr-public@npm:3.1053.0"
|
||||
dependencies:
|
||||
"@aws-crypto/sha256-browser": "npm:5.2.0"
|
||||
"@aws-crypto/sha256-js": "npm:5.2.0"
|
||||
@@ -241,13 +241,13 @@ __metadata:
|
||||
"@smithy/node-http-handler": "npm:^4.7.3"
|
||||
"@smithy/types": "npm:^4.14.2"
|
||||
tslib: "npm:^2.6.2"
|
||||
checksum: 10/bafc8332aba14d368037d96501f0c58afbc578908419a8428272894eaabb8123aba13ea62b722fd0fc2b9c55414d07fd01d6e250de008520e19fd53b5d8bac80
|
||||
checksum: 10/12dce323c41c037f5eab138f9fb77e65a61097f4cc28abd5ed984967efe97abec9bf00717b4e1199f0dca2bc135f4a81404490c9a21c3ed9b62da5fd1163de9b
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@aws-sdk/client-ecr@npm:^3.1050.0":
|
||||
version: 3.1052.0
|
||||
resolution: "@aws-sdk/client-ecr@npm:3.1052.0"
|
||||
"@aws-sdk/client-ecr@npm:^3.1053.0":
|
||||
version: 3.1053.0
|
||||
resolution: "@aws-sdk/client-ecr@npm:3.1053.0"
|
||||
dependencies:
|
||||
"@aws-crypto/sha256-browser": "npm:5.2.0"
|
||||
"@aws-crypto/sha256-js": "npm:5.2.0"
|
||||
@@ -259,7 +259,7 @@ __metadata:
|
||||
"@smithy/node-http-handler": "npm:^4.7.3"
|
||||
"@smithy/types": "npm:^4.14.2"
|
||||
tslib: "npm:^2.6.2"
|
||||
checksum: 10/b955225af6065a57a7139b175168782554d9e7e8bf6b87181eb9368efa7d790e4013d9cf93907efdfda86c17e23f8b0f6d3170ae3ad270792907a71d5a51658d
|
||||
checksum: 10/6d16180e9372b87da28c5bbfea93948874249734e2258d7d5d63abc80ccdc77617869e6c26fdf6539719e93cc721f83f44ad15b798290060bcf120a39112753c
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@@ -3214,8 +3214,8 @@ __metadata:
|
||||
resolution: "docker-login@workspace:."
|
||||
dependencies:
|
||||
"@actions/core": "npm:^3.0.1"
|
||||
"@aws-sdk/client-ecr": "npm:^3.1050.0"
|
||||
"@aws-sdk/client-ecr-public": "npm:^3.1050.0"
|
||||
"@aws-sdk/client-ecr": "npm:^3.1053.0"
|
||||
"@aws-sdk/client-ecr-public": "npm:^3.1053.0"
|
||||
"@docker/actions-toolkit": "npm:^0.90.0"
|
||||
"@eslint/js": "npm:^9.39.3"
|
||||
"@types/js-yaml": "npm:^4.0.9"
|
||||
|
||||
Reference in New Issue
Block a user