-
Notifications
You must be signed in to change notification settings - Fork 7
74 lines (64 loc) · 2.07 KB
/
deploy-prod.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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
name: "Deploy production"
"on":
workflow_dispatch:
inputs:
ref:
type: string
description: "The branch, tag or SHA to checkout"
required: true
default: "HEAD"
jobs:
build_and_deploy:
if: ${{ github.event.repository.full_name == github.repository }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
ref: "${{ github.event.inputs.ref }}"
fetch-depth: 0
# Whether to configure the token or SSH key with the local git config
# Default: true
persist-credentials: false # <--- checking this in commit context
- name: "Enable yarn cache"
uses: c-hive/gha-yarn-cache@v2 # using cache
- name: "Setup node@14"
uses: actions/setup-node@v2
with:
node-version: 14
- name: "Install dependencies"
run: |
yarn set version 3.1.1
yarn install
npm install -g firebase-tools
- name: "Build mainnet"
run: yarn run ci:build:mainnet
- name: "Setup node@18"
uses: actions/setup-node@v2
with:
node-version: 18
- name: "Deploy target: prod-mainnet"
uses: matter-labs/action-hosting-deploy@main
with:
repoToken: "${{ secrets.GITHUB_TOKEN }}"
firebaseServiceAccount: "${{ secrets.FIREBASE_SERVICE_ACCOUNT_FORCED_EXIT }}"
target: mainnet
projectId: forced-exit
channelID: live
- name: "Setup node@14"
uses: actions/setup-node@v2
with:
node-version: 14
- name: "Build goerli"
run: yarn run ci:build:goerli
- name: "Setup node@18"
uses: actions/setup-node@v2
with:
node-version: 18
- name: "Deploy target: prod-goerli"
uses: matter-labs/action-hosting-deploy@main
with:
repoToken: "${{ secrets.GITHUB_TOKEN }}"
firebaseServiceAccount: "${{ secrets.FIREBASE_SERVICE_ACCOUNT_FORCED_EXIT }}"
target: goerli
projectId: forced-exit
channelID: live