-
Notifications
You must be signed in to change notification settings - Fork 20
35 lines (30 loc) · 911 Bytes
/
nodejs.yml
File metadata and controls
35 lines (30 loc) · 911 Bytes
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
33
34
35
name: Documentation CI
on:
push:
branches:
- master
jobs:
build_and_deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2-beta
with:
node-version: '12'
- name: Installing packages
run: yarn install
- name: Build Gridsome site
run: node -v && yarn build
- name: Check AWS CLI
run: aws --version
- name: Sync to S3
run: |
# Sync dist with S3 bucket
aws s3 sync ./dist/ s3://docs.8base.com/
# Invalidate last Cloudfront distribution
aws cloudfront create-invalidation --distribution-id EZWU2FBHP41E9 --paths '/*'
env:
AWS_DEFAULT_REGION: us-east-1
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
CI: true