Skip to content

Commit 722da98

Browse files
use ecr
1 parent 8d55613 commit 722da98

File tree

1 file changed

+10
-12
lines changed

1 file changed

+10
-12
lines changed

.github/workflows/publish.yaml

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -20,18 +20,22 @@ jobs:
2020
- name: Check out the repo
2121
uses: actions/checkout@v4
2222

23-
- name: Log in to Docker Hub
24-
uses: docker/login-action@v3
23+
- name: Configure AWS credentials
24+
uses: aws-actions/configure-aws-credentials@v1
2525
with:
26-
registry: ghcr.io
27-
username: ${{ github.actor }}
28-
password: ${{ secrets.GITHUB_TOKEN }}
26+
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
27+
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
28+
aws-region: us-west-2
29+
30+
- name: Login to Amazon ECR
31+
id: login-ecr
32+
uses: aws-actions/amazon-ecr-login@v1
2933

3034
- name: Extract metadata (tags, labels) for Docker
3135
id: meta
3236
uses: docker/metadata-action@v5
3337
with:
34-
images: ghcr.io/fiboa/fiboa-sda
38+
images: 767828762635.dkr.ecr.us-west-1.amazonaws.com/fiboa/fiboa-sda
3539

3640
- name: Build and push Docker image
3741
id: push
@@ -43,9 +47,3 @@ jobs:
4347
tags: ${{ steps.meta.outputs.tags }}
4448
labels: ${{ steps.meta.outputs.labels }}
4549

46-
- name: Generate artifact attestation
47-
uses: actions/attest-build-provenance@v2
48-
with:
49-
subject-name: index.docker.io/my-docker-hub-namespace/my-docker-hub-repository
50-
subject-digest: ${{ steps.push.outputs.digest }}
51-
push-to-registry: true

0 commit comments

Comments
 (0)