-
Notifications
You must be signed in to change notification settings - Fork 6
72 lines (71 loc) · 2.52 KB
/
scan-firebase-hosting-merge.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
# This file was auto-generated by the Firebase CLI
# https://github.com/firebase/firebase-tools
name: Deploy Scan to Firebase Hosting on merge
'on':
push:
branches:
- scan
- scan-dev
jobs:
prod_build_and_deploy:
if: github.ref == 'refs/heads/scan'
runs-on: ubuntu-latest
environment:
name: production
url: https://scan.s3.xyz
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '18'
- run: |
cd packages/client/scan
yarn
yarn build
env:
CI: false
REACT_APP_NAME: 'US3R SCAN'
REACT_APP_API_BASE_URL: '${{ vars.REACT_APP_API_BASE_URL }}'
REACT_APP_UPLOAD_API_URL: '${{ vars.REACT_APP_UPLOAD_API_URL }}'
REACT_APP_CERAMIC_MAINNET_HOST: '${{ vars.REACT_APP_CERAMIC_MAINNET_HOST }}'
REACT_APP_CERAMIC_TESTNET_HOST: '${{ vars.REACT_APP_CERAMIC_TESTNET_HOST }}'
REACT_APP_ADMIN_ADDRESS: '${{ vars.REACT_APP_ADMIN_ADDRESS }}'
- uses: FirebaseExtended/action-hosting-deploy@v0
with:
repoToken: '${{ secrets.GITHUB_TOKEN }}'
firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_US3R_NETWORK }}'
channelId: live
projectId: us3r-network
target: scan
entryPoint: './packages/client/scan/'
dev_build_and_deploy:
if: github.ref == 'refs/heads/scan-dev'
runs-on: ubuntu-latest
environment:
name: development
url: https://scan-dev.s3.xyz
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '18'
- run: |
cd packages/client/scan
yarn
yarn build
env:
CI: false
REACT_APP_NAME: 'US3R SCAN DEV'
REACT_APP_API_BASE_URL: '${{ vars.REACT_APP_API_BASE_URL }}'
REACT_APP_UPLOAD_API_URL: '${{ vars.REACT_APP_UPLOAD_API_URL }}'
REACT_APP_CERAMIC_MAINNET_HOST: '${{ vars.REACT_APP_CERAMIC_MAINNET_HOST }}'
REACT_APP_CERAMIC_TESTNET_HOST: '${{ vars.REACT_APP_CERAMIC_TESTNET_HOST }}'
REACT_APP_ADMIN_ADDRESS: '${{ vars.REACT_APP_ADMIN_ADDRESS }}'
- uses: FirebaseExtended/action-hosting-deploy@v0
with:
repoToken: '${{ secrets.GITHUB_TOKEN }}'
firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_US3R_NETWORK }}'
channelId: live
projectId: us3r-network
target: scan-dev
entryPoint: './packages/client/scan/'