Merge pull request #252 from np-complete/renovate/eslint-8.x-lockfile #209
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 | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
terraform: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- run: | | |
aws configure set aws_access_key_id ${{ secrets.AWS_ACCESS_KEY_ID }} --profile default | |
aws configure set aws_secret_access_key ${{ secrets.AWS_SECRET_ACCESS_KEY }} --profile default | |
- uses: hashicorp/setup-terraform@v3 | |
- working-directory: ./terraform | |
run: | | |
terraform init | |
terraform plan | |
terraform apply -auto-approve | |
deploy: | |
runs-on: ubuntu-latest | |
needs: terraform | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version-file: .node-version | |
cache: yarn | |
- run: yarn install | |
- run: yarn webpack --mode production | |
- uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
aws-region: us-west-2 | |
- run: aws s3 sync dist s3://np-complete-doj.in --follow-symlinks --delete | |
- run: aws cloudfront create-invalidation --distribution-id "E3VHLM8V7ZZNLS" --paths "/*" |