Skip to content

⚙ update deployment configuration #29

⚙ update deployment configuration

⚙ update deployment configuration #29

Workflow file for this run

name: Deploy React App to S3
on:
push:
branches:
- main # Trigger this workflow on push to main branch
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Install dependencies and build
run: |
yarn install
yarn run build
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_S3_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_S3_SECRET_ACCESS_KEY_ID }}
aws-region: ap-northeast-2
- name: Deploy to S3
run: |
aws s3 sync dist/ s3://${{ secrets.AWS_S3_BUCKET_NAME }} --delete
- name: Invalidate CloudFront Distribution
run: aws cloudfront create-invalidation --distribution-id ${{AWS_DISTRIBUTION_ID}} --paths "/*"

Check failure on line 33 in .github/workflows/deploy.yaml

View workflow run for this annotation

GitHub Actions / Deploy React App to S3

Invalid workflow file

The workflow is not valid. .github/workflows/deploy.yaml (Line: 33, Col: 14): Unrecognized named-value: 'AWS_DISTRIBUTION_ID'. Located at position 1 within expression: AWS_DISTRIBUTION_ID