Skip to content

Commit

Permalink
Update publish.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
marciogoda authored Apr 23, 2024
1 parent b637c75 commit 07d2750
Showing 1 changed file with 18 additions and 2 deletions.
20 changes: 18 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ on:

jobs:
publish:
runs-on: ubuntu-latest
runs-on: [self-hosted, linux, aws]
name: Publish docker image
if: github.event.workflow_run.conclusion == 'success'
steps:
Expand All @@ -19,6 +19,19 @@ jobs:
with:
username: ${{ secrets.DOCKERHUB_USER }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}

- name: Login AWS
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: arn:aws:iam::724178030834:role/capplatform-deploy
aws-access-key-id: ${{ secrets.CAPPLATFORM_AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.CAPPLATFORM_AWS_SECRET_ACCESS_KEY }}
aws-region: us-east-1

- name: Login AWS ECR
uses: aws-actions/amazon-ecr-login@v2
with:
registry-type: public

- name: Set up QEMU
uses: docker/setup-qemu-action@v2
Expand All @@ -30,4 +43,7 @@ jobs:
uses: docker/build-push-action@v3
with:
push: true
tags: mergermarket/cdflow2-config-aws-simple:latest
platforms: linux/amr64,linux/amd64
tags: |
mergermarket/cdflow2-config-aws-simple:latest
public.ecr.aws/p7e3d1i3/cdflow2-config-aws-simple:latest

0 comments on commit 07d2750

Please sign in to comment.