diff --git a/.github/workflows/build-deploy.yaml b/.github/workflows/build-deploy.yaml index 0c96b95..328a4c4 100644 --- a/.github/workflows/build-deploy.yaml +++ b/.github/workflows/build-deploy.yaml @@ -11,12 +11,6 @@ permissions: contents: read env: - AWS_REGION: eu-central-1 - ECR_REPOSITORY: cognipeer-cgate - - ACR_LOGIN_SERVER: cognipeer.azurecr.io - ACR_REPOSITORY: cognipeer-cgate - HELM_VERSION: v3.15.2 HELMFILE_VERSION: v0.162.0 @@ -30,8 +24,8 @@ jobs: - name: Configure AWS credentials (OIDC) uses: aws-actions/configure-aws-credentials@v4 with: - role-to-assume: arn:aws:iam::339713139704:role/GitHubActionsECRPushRole - aws-region: ${{ env.AWS_REGION }} + role-to-assume: ${{secrets.ROLE_PROVIDER}} + aws-region: ${{ secrets.AWS_REGION }} - name: Login to Amazon ECR id: ecr @@ -49,7 +43,7 @@ jobs: } - name: "[Azure] Login to ACR" - run: az acr login --name ${{ env.ACR_LOGIN_SERVER }} + run: az acr login --name ${{ secrets.LOGIN_SERVER }} - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 @@ -77,8 +71,8 @@ jobs: cache-from: type=gha cache-to: type=gha,mode=max tags: | - ${{ steps.ecr.outputs.registry }}/${{ env.ECR_REPOSITORY }}:${{ steps.vars.outputs.tag }} - ${{ env.ACR_LOGIN_SERVER }}/${{ env.ACR_REPOSITORY }}:${{ steps.vars.outputs.tag }} + ${{ steps.ecr.outputs.registry }}/${{ secrets.LOCAL_FIRST_REPOSITORY }}:${{ steps.vars.outputs.tag }} + ${{ env.LOGIN_SERVER }}/${{ secrets.LOCAL_SECOND_REPOSITORY }}:${{ steps.vars.outputs.tag }} notify: runs-on: ubuntu-latest