-
Notifications
You must be signed in to change notification settings - Fork 0
50 lines (40 loc) · 1.13 KB
/
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
name: deploy to prod
on:
push:
branches:
- main
jobs:
prod:
name: 'prod'
timeout-minutes: 15
runs-on: ubuntu-latest
steps:
- name: checkout repository
uses: actions/checkout@v4
- name: set frontend env
run: mkdir -p src/environments && touch src/environments/environment.ts && echo "${{ secrets.ENV_PROD }}" >> src/environments/environment.prod.ts
- name: update node
uses: actions/setup-node@v4
with:
node-version: '18'
cache: 'npm'
- name: install dependencies
run: npm ci
- name: lint
run: npm run lint
- name: build
run: npm run build -- --configuration production
- name: install dependencies in functions
run: cd functions && npm ci
- name: lint
run: npm run lint
# TODO: テストが整ったら入れる
# - name: test
# run: npm run test
- name: deploy to firebase
uses: w9jds/firebase-action@v13.22.1
with:
args: deploy
env:
GCP_SA_KEY: ${{ secrets.GCP_SA_KEY_PROD }}
PROJECT_ID: prod