-
Notifications
You must be signed in to change notification settings - Fork 3
32 lines (30 loc) · 1.06 KB
/
builder.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
name: Build and deploy
on: push
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: ruby/setup-ruby@v1
with:
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
- name: make site
run: bundle exec jekyll build
- name: deploy to S3
uses: jakejarvis/s3-sync-action@master
if: contains(github.ref, 'master')
with:
args: --acl public-read --follow-symlinks --delete --cache-control max-age=600
env:
AWS_S3_BUCKET: 'www.nateberkopec.com'
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_REGION: 'us-east-1'
SOURCE_DIR: '_site'
- name: Cloudflare Purge Cache
uses: jakejarvis/[email protected]
if: contains(github.ref, 'master')
env:
# Zone is required by both authentication methods
CLOUDFLARE_ZONE: ${{ secrets.CLOUDFLARE_ZONE }}
CLOUDFLARE_TOKEN: ${{ secrets.CLOUDFLARE_TOKEN }}