Use native AWS CLI to upload to S3

This commit is contained in:
Alicia Sykes 2023-08-30 20:07:28 +01:00
parent cd2681fd84
commit 8688fd23f5

View File

@ -53,14 +53,17 @@ jobs:
yarn install
yarn build
- name: Upload to S3
uses: shallwefootball/s3-upload-action@v1.3.3
id: S3
- name: Setup AWS
uses: aws-actions/configure-aws-credentials@v1
with:
aws_key_id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws_secret_access_key: ${{ secrets.AWS_SECRET_ACCESS_KEY}}
aws_bucket: 'web-check-frontend'
source_dir: './'
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: us-east-1
- name: Upload to S3
env:
AWS_S3_BUCKET: 'web-check-frontend'
run: aws s3 sync ./build/ s3://$AWS_S3_BUCKET/ --delete
- name: Invalidate CloudFront cache
uses: chetan/invalidate-cloudfront-action@v2.4