Skip to content

chore(deps): update dependency crate-ci/typos to v1.29.0 (#487) #499

chore(deps): update dependency crate-ci/typos to v1.29.0 (#487)

chore(deps): update dependency crate-ci/typos to v1.29.0 (#487) #499

Workflow file for this run

name: Deploy to Cloudflare
on:
push:
branches:
- main
jobs:
build-and-deploy:
timeout-minutes: 10
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: aquaproj/aqua-installer@e6160e5a751bbcbd337a834eb75c15ba9ca206ae # v3.0.2
with:
aqua_version: v2.41.0
- name: Build
run: |
git submodule init
git submodule update
hugo
- name: Setup aws-cli for Cloudflare
run: |
echo "AWS_ACCESS_KEY_ID=$AWS_ACCESS_KEY_ID" >> $GITHUB_ENV
echo "AWS_SECRET_ACCESS_KEY=$AWS_SECRET_ACCESS_KEY" >> $GITHUB_ENV
echo "AWS_DEFAULT_REGION=auto" >> $GITHUB_ENV
echo "ENDPOINT=$ENDPOINT" >> $GITHUB_ENV
env:
AWS_ACCESS_KEY_ID: ${{secrets.AWS_ACCESS_KEY_ID}}
AWS_SECRET_ACCESS_KEY: ${{secrets.AWS_SECRET_ACCESS_KEY}}
ENDPOINT: ${{secrets.S3_ENDPOINT}}
- name: Upload to R2
working-directory: public
run: aws s3 sync . s3://portfolio --endpoint-url $ENDPOINT
- name: Send purge request to Fastly
run: fastly purge --service-name portfolio --all
env:
FASTLY_API_TOKEN: ${{secrets.FASTLY_API_TOKEN}}