Skip to content
This repository was archived by the owner on Jul 7, 2023. It is now read-only.

Commit 37093af

Browse files
committed
fix: switch to aws roles
1 parent 315d979 commit 37093af

File tree

2 files changed

+12
-4
lines changed

2 files changed

+12
-4
lines changed

.github/workflows/mirror.yml

+6-2
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,16 @@ jobs:
1414
permissions:
1515
contents: read
1616
packages: write
17+
id-token: write
1718
steps:
19+
- name: configure aws credentials
20+
uses: aws-actions/configure-aws-credentials@v1
21+
with:
22+
role-to-assume: ${{ secrets.PROD_AWS_ROLE }}
23+
aws-region: us-east-1
1824
- uses: docker/login-action@v2
1925
with:
2026
registry: public.ecr.aws
21-
username: ${{ secrets.PROD_ACCESS_KEY_ID }}
22-
password: ${{ secrets.PROD_SECRET_ACCESS_KEY }}
2327
- uses: docker/login-action@v2
2428
with:
2529
registry: ghcr.io

.github/workflows/publish.yml

+6-2
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ jobs:
1616
permissions:
1717
contents: read
1818
packages: write
19+
id-token: write
1920
steps:
2021
- id: meta
2122
uses: docker/metadata-action@v4
@@ -36,12 +37,15 @@ jobs:
3637
with:
3738
username: ${{ secrets.DOCKER_USERNAME }}
3839
password: ${{ secrets.DOCKER_PASSWORD }}
40+
- name: configure aws credentials
41+
uses: aws-actions/configure-aws-credentials@v1
42+
with:
43+
role-to-assume: ${{ secrets.PROD_AWS_ROLE }}
44+
aws-region: us-east-1
3945
- name: Login to ECR
4046
uses: docker/login-action@v2
4147
with:
4248
registry: public.ecr.aws
43-
username: ${{ secrets.PROD_ACCESS_KEY_ID }}
44-
password: ${{ secrets.PROD_SECRET_ACCESS_KEY }}
4549
- name: Login to GHCR
4650
uses: docker/login-action@v2
4751
with:

0 commit comments

Comments
 (0)