Bump prettier from 3.3.2 to 3.3.3 (#54) #45
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: jessicabrentnall Deploy to CO.UK | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Ruby 3.1.x | |
uses: actions/setup-ruby@v1 | |
with: | |
ruby-version: 3.1.x | |
- name: Install Packages | |
run: | | |
npm run install-jekyll | |
- name: Build Jekyll | |
working-directory: ./site | |
run: | | |
bundle exec jekyll build | |
- name: Set AWS CLI | |
env: | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_ACCESS_SECRET_KEY }} | |
run: | | |
sudo pip install --upgrade pip | |
echo "pip upgraded" | |
pip install --user awscli | |
echo "AWS CLI installed" | |
aws configure set aws_access_key_id "$AWS_ACCESS_KEY_ID" | |
aws configure set aws_secret_access_key "$AWS_SECRET_ACCESS_KEY" | |
aws configure set region eu-west-2 | |
aws configure set output json | |
echo "AWS CLI configured" | |
- name: Deploy To S3 | |
run: | | |
aws s3 sync ./site/_site/ s3://jessicabrentnall.co.uk/ --delete | |
echo "Deployed to S3" | |
- name: Invalidate CloudFront cache | |
run: | | |
aws cloudfront create-invalidation --distribution-id EC8POOU1IP5LQ --paths "/*" | |
echo 'Invalidated CloudFront cache' |