This repository has been archived by the owner on Jan 3, 2025. It is now read-only.
Bump aws-sdk-sqs from 1.62.0 to 1.63.0 (#242) #107
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: main | |
jobs: | |
main: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Configure AWS credentials | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
aws-access-key-id: ${{ secrets.CI_CD_AWS_ACCESS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.CI_CD_AWS_SECRET_ACCESS_KEY }} | |
aws-region: ${{ secrets.AWS_DEFAULT_REGION }} | |
- name: Login to Amazon ECR | |
id: login-ecr | |
uses: aws-actions/amazon-ecr-login@v1 | |
- name: Build and push handler | |
uses: docker/build-push-action@v5 | |
with: | |
context: . | |
push: true | |
file: dockerfile.handler | |
tags: ${{ steps.login-ecr.outputs.registry }}/wca-registration-handler:latest | |
cache-from: type=gha | |
cache-to: type=gha,mode=max | |
- name: Build and push worker | |
uses: docker/build-push-action@v5 | |
with: | |
context: . | |
push: true | |
file: dockerfile.worker | |
tags: ${{ steps.login-ecr.outputs.registry }}/wca-registration-worker:latest | |
cache-from: type=gha | |
cache-to: type=gha,mode=max | |
- name: Deploy worker | |
run: | | |
aws ecs update-service --cluster wca-registration --service wca-registration-worker --force-new-deployment | |
- name: Deploy Frontend | |
run: | | |
cd ./Frontend | |
npm install | |
npm run build:prod | |
aws s3 sync dist s3://assets.registration.worldcubeassociation.org/dist | |
aws cloudfront create-invalidation --distribution-id E322K044MBR5FG --paths "/dist/*" --output text |