Skip to content

Commit

Permalink
upload static website to s3 using aws cli tool
Browse files Browse the repository at this point in the history
  • Loading branch information
Atomsoldat committed Dec 28, 2024
1 parent 2591ebf commit f3ae19a
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,11 @@ jobs:
name: website
path: './public'
# upload to s3
- uses: shallwefootball/s3-upload-action@master
with:
aws_key_id: ${{ secrets.S3_KEY_ID }}
aws_secret_access_key: ${{ secrets.S3_SECRET_ACCESS_KEY }}
aws_bucket: ${{ secrets.S3_BUCKET }}
endpoint: ${{ secrets.S3_ENDPOINT }}
source_dir: './public'
- name: Configure AWS CLI for Hetzner S3
run: |
aws configure set aws_access_key_id ${{ secrets.S3_KEY_ID }}
aws configure set aws_secret_access_key ${{ secrets.S3_SECRET_ACCESS_KEY }}
aws configure set s3.endpoint_url ${{ secrets.S3_ENDPOINT }}
- name: Upload files to Hetzner S3
run: |
aws s3 sync ./public ${{ secrets.S3_BUCKET }} --delete

0 comments on commit f3ae19a

Please sign in to comment.