-
Notifications
You must be signed in to change notification settings - Fork 2
128 lines (115 loc) · 4.14 KB
/
netlify.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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
name: Build and Deploy to Netlify
on:
push:
branches:
- develop
- d/**
pull_request:
jobs:
build-dev-vocdoni:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20.x
- name: Cache Node.js modules
uses: actions/cache@v4
with:
path: node_modules
key: ${{ runner.os }}-node-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install
run: yarn
- name: Lint
run: yarn lint
- name: Build vocdoni app dev
run: yarn build
env:
VOCDONI_ENVIRONMENT: dev
FEATURES: >-
{
"vote":{"customization":true},
"unimplemented_census":["phone","email","crm","database","digital_certificate"],
"unimplemented_voting_type":["multi","participatory","borda"],
"login":["web2","web3", "recovery"],
"census":["spreadsheet", "csp"],
"languages":["ca", "es", "en"]
}
CUSTOM_ORGANIZATION_DOMAINS: ${{ secrets.CUSTOM_ORGANIZATION_DOMAINS }}
CSP_URL: ${{ secrets.CSP_URL }}}
CSP_PUBKEY: ${{ secrets.CSP_PUBKEY }}
STRIPE_PUBLIC_KEY: pk_test_51P6vaOI1T5UnHYElxQ2aqpc7DZET6spnYww8ItU7rOv94OTHlGzvh4fK3Z5HVTGT2KmGLnDCcUnvBUjODYiL61W600XBPAnoZZ
THEME: saas
SAAS_URL: https://saas-dev.vocdoni.app/
- name: Deploy to Netlify
uses: nwtgck/[email protected]
with:
publish-dir: './dist'
# keep as a non existant branch, because we don't want to publish this
production-branch: develop
github-token: ${{ secrets.GITHUB_TOKEN }}
deploy-message: 'Vocdoni DEV Deploy from GitHub Actions'
enable-pull-request-comment: true
enable-commit-comment: true
overwrites-pull-request-comment: true
env:
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
NETLIFY_SITE_ID: 5bddb63a-3f70-4de9-9fa8-89afc6f813a8
timeout-minutes: 1
build-stg-vocdoni:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20.x
- name: Cache Node.js modules
uses: actions/cache@v4
with:
path: node_modules
key: ${{ runner.os }}-node-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install
run: yarn
- name: Lint
run: yarn lint
- name: Build vocdoni app stg
run: yarn build
env:
VOCDONI_ENVIRONMENT: stg
FEATURES: >-
{
"vote":{"customization":true},
"unimplemented_census":["phone","email","crm","database","digital_certificate"],
"unimplemented_voting_type":["multi","participatory","borda"],
"login":["web2","web3", "recovery"],
"census":["spreadsheet", "csp"],
"languages":["ca", "es", "en"]
}
CUSTOM_ORGANIZATION_DOMAINS: ${{ secrets.CUSTOM_ORGANIZATION_DOMAINS }}
CSP_URL: ${{ secrets.CSP_URL }}}
CSP_PUBKEY: ${{ secrets.CSP_PUBKEY }}
STRIPE_PUBLIC_KEY: pk_test_51PNuOtDW6VLep8WG8WFS7KZocugbzYbkuNn94WAxuGZUa1maPK7kv5BnEPN3x5bXLaCYhHRkBmmGJVVvcDkbbnbS00V4LExTPD
THEME: saas
SAAS_URL: https://saas-dev.vocdoni.app/
- name: Deploy to Netlify
uses: nwtgck/[email protected]
with:
publish-dir: './dist'
production-branch: develop
github-token: ${{ secrets.GITHUB_TOKEN }}
deploy-message: 'Vocdoni STG Deploy from GitHub Actions'
enable-pull-request-comment: true
enable-commit-comment: true
overwrites-pull-request-comment: true
env:
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
NETLIFY_SITE_ID: 5f9bd529-1b25-49af-acde-818bbd33109b
timeout-minutes: 1