generated from chiffre-io/template-website
-
-
Notifications
You must be signed in to change notification settings - Fork 1
40 lines (36 loc) · 1.18 KB
/
cd.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
33
34
35
36
37
38
39
40
name: Continuous Delivery
on:
push:
branches:
- master
jobs:
cd:
name: Continuous Delivery
runs-on: ubuntu-latest
steps:
- id: yarn-cache
name: Get Yarn cache path
run: echo "::set-output name=dir::$(yarn cache dir)"
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- uses: actions/setup-node@56899e050abffc08c2b3b61f3ec6a79a9dc3223d
with:
node-version: 14.x
- uses: actions/cache@c3f1317a9e7b1ef106c153ac8c0f00fed3ddbc0d
name: Load Yarn cache
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- run: yarn install --ignore-scripts
name: Install dependencies
- run: yarn build
name: Build web app
# Continuous Delivery Pipeline --
- uses: dswistowski/surge-sh-action@c20b9ece7374f66af0b5f21e03587fc55bafa919
name: Publish to Surge
with:
domain: ${{ secrets.DEPLOYMENT_URL }}
project: ./out
login: ${{ secrets.SURGE_LOGIN }}
token: ${{ secrets.SURGE_TOKEN }}