Compare commits
3 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6c254bfa5f | ||
|
|
c7939d0b1a | ||
|
|
d434c84a4a |
3 changed files with 2 additions and 2 deletions
|
|
@ -4,11 +4,11 @@ on:
|
|||
build_cmd: { required: true, type: string }
|
||||
dist_dir: { required: true, type: string }
|
||||
s3_bucket: { required: true, type: string }
|
||||
cf_dist_id: { required: true, type: string }
|
||||
exclude_glob: { required: false, type: string, default: "" }
|
||||
secrets:
|
||||
AWS_ACCESS_KEY_ID: { required: true }
|
||||
AWS_SECRET_ACCESS_KEY: { required: true }
|
||||
CF_DIST_ID: { required: true }
|
||||
jobs:
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
|
|
@ -23,4 +23,4 @@ jobs:
|
|||
EXCLUDES=""
|
||||
[ -n "${{ inputs.exclude_glob }}" ] && for g in ${{ inputs.exclude_glob }}; do EXCLUDES="$EXCLUDES --exclude $g"; done
|
||||
aws s3 sync ${{ inputs.dist_dir }}/ s3://${{ inputs.s3_bucket }}/ --delete $EXCLUDES
|
||||
aws cloudfront create-invalidation --distribution-id ${{ inputs.cf_dist_id }} --paths "/*"
|
||||
aws cloudfront create-invalidation --distribution-id "${{ secrets.CF_DIST_ID }}" --paths "/*"
|
||||
Loading…
Reference in a new issue