Skip to content

Update main.yml

Update main.yml #13

Workflow file for this run

name: S3 Deploy
on:
push:
branches:
- master
jobs:
run:
runs-on: ubuntu-latest
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
steps:
- uses: actions/checkout@v4
with:
path: './repo'
- name: Deploy
run: |
npm i s3-deploy
cd ./repo
npx s3-deploy './**' --cwd './' --region ${{ secrets.S3_BUCKET_REGION }} --bucket ${{ secrets.S3_BUCKET }} --distId ${{ secrets.CLOUDFRONT_DISTRIBUTION_ID }} --deleteRemoved --invalidate '/'