eimmigrate-prod deploy deploy-for-2024 workflow_dispatch by nickkats #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: deploy | |
run-name: ${{ github.event.inputs.env }} deploy ${{ github.ref_name }} ${{ github.event_name }} by ${{ github.actor }} | |
on: | |
workflow_dispatch: | |
inputs: | |
env: | |
type: environment | |
ref: | |
description: 'Branch, Tag, or Full SHA' | |
required: true | |
default: 'master' | |
concurrency: | |
group: ${{ github.event.inputs.env }} | |
permissions: | |
id-token: write | |
contents: read | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
environment: | |
name: ${{ github.event.inputs.env }} | |
env: | |
DEPLOYMENT: ${{ github.event.inputs.env }} | |
AWS_ECR_REPOSITORY: ${{ secrets.AWS_ACCOUNT_ID }}.dkr.ecr.us-west-2.amazonaws.com/eimmigrate | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: aws-actions/configure-aws-credentials@v2 | |
with: | |
role-to-assume: arn:aws:iam::${{ secrets.AWS_ACCOUNT_ID }}:role/github-actions | |
role-session-name: gha | |
aws-region: us-west-2 | |
- id: login-ecr | |
uses: aws-actions/amazon-ecr-login@v1 | |
- run: make deploy | |
- run: make deploy-status |