Skip to content

Commit 2b60080

Browse files
authored
Move site deployments to use netlify-cli (#846)
1 parent d932ffa commit 2b60080

File tree

6 files changed

+5104
-327
lines changed

6 files changed

+5104
-327
lines changed

.github/workflows/deploy-site.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Deploy site
2+
3+
on: push
4+
5+
jobs:
6+
deploy-site:
7+
name: Deploy site
8+
runs-on: ubuntu-latest
9+
env:
10+
CI: true
11+
steps:
12+
- name: Checkout Repo
13+
uses: actions/checkout@main
14+
15+
- uses: pnpm/[email protected]
16+
17+
- name: Set up Node.js
18+
uses: actions/setup-node@main
19+
with:
20+
node-version-file: '.nvmrc'
21+
cache: 'pnpm'
22+
23+
- name: Install Dependencies
24+
run: pnpm i
25+
26+
- name: Build packages
27+
run: pnpm run build
28+
29+
- name: Build site
30+
run: pnpm --filter "./site" build
31+
32+
- name: Draft deploy site to Netlify
33+
run: pnpm --filter "./site" deploy:branch
34+
if: github.ref != 'refs/heads/master'
35+
env:
36+
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
37+
38+
- name: Deploy site to Netlify
39+
run: pnpm --filter "./site" deploy:prod
40+
if: github.ref == 'refs/heads/master'
41+
env:
42+
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}

.github/workflows/release.yml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,15 @@ jobs:
1212
env:
1313
CI: true
1414
steps:
15-
- uses: pnpm/[email protected]
16-
with:
17-
version: 7.9.5
18-
1915
- name: Checkout Repo
2016
uses: actions/checkout@main
2117
with:
2218
fetch-depth: 0
2319
token: ${{ secrets.SEEK_OSS_CI_GITHUB_TOKEN }}
2420

25-
- name: Setup Node.js
21+
- uses: pnpm/[email protected]
22+
23+
- name: Set up Node.js
2624
uses: actions/setup-node@main
2725
with:
2826
node-version-file: '.nvmrc'

.github/workflows/snapshot.yml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,18 +9,16 @@ jobs:
99
env:
1010
CI: true
1111
steps:
12-
- uses: pnpm/[email protected]
13-
with:
14-
version: 7.9.5
15-
1612
- name: Checkout Repo
1713
uses: actions/checkout@main
1814
with:
1915
# This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits
2016
fetch-depth: 0
2117
token: ${{ secrets.SEEK_OSS_CI_GITHUB_TOKEN }}
2218

23-
- name: Setup Node.js
19+
- uses: pnpm/[email protected]
20+
21+
- name: Set up Node.js
2422
uses: actions/setup-node@main
2523
with:
2624
node-version-file: '.nvmrc'

.github/workflows/validate.yml

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,12 @@ jobs:
99
env:
1010
CI: true
1111
steps:
12-
- uses: pnpm/[email protected]
13-
with:
14-
version: 7.9.5
15-
1612
- name: Checkout Repo
1713
uses: actions/checkout@main
1814

19-
- name: Setup Node.js
15+
- uses: pnpm/[email protected]
16+
17+
- name: Set up Node.js
2018
uses: actions/setup-node@main
2119
with:
2220
node-version-file: '.nvmrc'
@@ -39,14 +37,12 @@ jobs:
3937
env:
4038
CI: true
4139
steps:
42-
- uses: pnpm/[email protected]
43-
with:
44-
version: 7.9.5
45-
4640
- name: Checkout Repo
4741
uses: actions/checkout@main
4842

49-
- name: Setup Node.js
43+
- uses: pnpm/[email protected]
44+
45+
- name: Set up Node.js
5046
uses: actions/setup-node@main
5147
with:
5248
node-version-file: '.nvmrc'

0 commit comments

Comments
 (0)