Skip to content

Sync to S3

Sync to S3 #8

name: Sync to S3
on:
workflow_run:
workflows: ["Build and Push"]
types:
- completed
jobs:
deploy:
if: ${{ github.event.workflow_run.conclusion == 'success' }}
runs-on: ubuntu-latest
steps:
- name: Checkout gh-pages
uses: actions/checkout@v4
with:
ref: jpl
- name: Sync to S3
uses: jakejarvis/s3-sync-action@master
with:
args: --delete --exclude '.git/*'
env:
AWS_S3_BUCKET: ${{ secrets.S3_BUCKET }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_REGION: 'us-west-2'
SOURCE_DIR: '.' # or 'public' or whatever the root is