Skip to content

Commit

Permalink
Correct release.yml (point to MP)
Browse files Browse the repository at this point in the history
  • Loading branch information
Gary-H9 committed Mar 19, 2024
1 parent 3c03698 commit 4dbfccb
Showing 1 changed file with 16 additions and 11 deletions.
27 changes: 16 additions & 11 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,37 +19,42 @@ jobs:
steps:
- name: Checkout
id: checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # v4.1.2

- name: Install cosign
id: install_cosign
uses: sigstore/cosign-installer@e1523de7571e31dbe865fd2e80c5c7c23ae71eb4 # v3.4.0

- name: Log in to GitHub Container Registry
id: login_ghcr
uses: docker/login-action@343f7c4344506bcbf9b4de18042ae17996df046d # v3.0.0
- name: Configure AWS Credentials
id: configure_aws_credentials
uses: aws-actions/configure-aws-credentials@e3dd6a429d7300a6a4c196c26e071d42e0343502 # v4.0.2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
aws-region: eu-west-2
role-to-assume: arn:aws:iam::730335344807:role/modernisation-platform-oidc-cicd

- name: Login to Amazon ECR
id: login_ecr
uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076
with:
registries: 374269020027

- name: Build and Push
id: build_and_push
uses: docker/build-push-action@4a13e500e55cf31b7a5d59a38ab2040ab0f42f56 # v5.1.0
uses: docker/build-push-action@2cdde995de11925a030ce8070c3d77a52ffcf1c0 # v5.3.0
with:
push: true
tags: ghcr.io/ministryofjustice/analytical-platform-ingestion-transfer:${{ github.ref_name }}
tags: 374269020027.dkr.ecr.eu-west-2.amazonaws.com/analytical-platform-ingestion-transfer:${{ github.ref_name }}

- name: Sign
id: sign
shell: bash
run: |
cosign sign --yes ghcr.io/ministryofjustice/analytical-platform-ingestion-transfer@${{ steps.build_and_push.outputs.digest }}
cosign sign --yes 374269020027.dkr.ecr.eu-west-2.amazonaws.com/analytical-platform-ingestion-transfer@${{ steps.build_and_push.outputs.digest }}
- name: Verify
id: verify
run: |
cosign verify \
--certificate-oidc-issuer=https://token.actions.githubusercontent.com \
--certificate-identity=https://github.com/ministryofjustice/analytical-platform-ingestion-transfer/.github/workflows/release.yml@refs/tags/${{ github.ref_name }} \
ghcr.io/ministryofjustice/analytical-platform-ingestion-transfer@${{ steps.build_and_push.outputs.digest }}
374269020027.dkr.ecr.eu-west-2.amazonaws.com/analytical-platform-ingestion-transfer@${{ steps.build_and_push.outputs.digest }}

0 comments on commit 4dbfccb

Please sign in to comment.