@leverege/build-tools 2.50.6 → 2.50.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +4 -4
- package/src/helm-charts/api-server/values-local.yaml +4 -4
- package/src/helm-charts/authz-server/values-local.yaml +2 -2
- package/src/helm-charts/cnpg-db-pgbench/cluster.yaml.ovh +2 -2
- package/src/helm-charts/cnpg-db-psql-stack/cluster.yaml.ovh +1 -1
- package/src/helm-charts/cnpg-db-tsdb-basic/cluster.yaml.ovh +1 -1
- package/src/helm-charts/cnpg-db-tsdb-dense/cluster.yaml.ovh +1 -1
- package/src/helm-charts/db-curator/values-local.yaml +1 -1
- package/src/helm-charts/emailer/values-local.yaml +1 -1
- package/src/helm-charts/fota-server/values-local.yaml +2 -2
- package/src/helm-charts/message-processor/values-local.yaml +1 -1
- package/src/helm-charts/messenger/values-local.yaml +1 -1
- package/src/helm-charts/resource-server/values-local.yaml +5 -2
- package/src/helm-charts/rule-engine/values-local.yaml +2 -2
- package/src/helm-charts/scheduler/values-local.yaml +2 -2
- package/src/helm-charts/transponder-bq/values-local.yaml +1 -1
- package/src/helm-charts/transponder-dh/values-local.yaml +4 -4
- package/src/helm-charts/transponder-rt/values-local.yaml +1 -1
- package/src/helm-charts/transponder-tsdb/values-local.yaml +2 -2
- package/src/helmup-cors-for-buckets.json +1 -0
- package/src/helmup.sh +37 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@leverege/build-tools",
|
|
3
|
-
"version": "2.50.
|
|
3
|
+
"version": "2.50.8",
|
|
4
4
|
"description": "A collection of build / support tools for Leverege developers",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"repository": {
|
|
@@ -64,10 +64,10 @@
|
|
|
64
64
|
"execa": "^8.0.1",
|
|
65
65
|
"glob": "^10.3.12",
|
|
66
66
|
"handlebars": "^4.7.8",
|
|
67
|
-
"inquirer": "^9.2.
|
|
67
|
+
"inquirer": "^9.2.20",
|
|
68
68
|
"js-yaml": "^4.1.0",
|
|
69
69
|
"ms": "^2.1.3",
|
|
70
|
-
"npm-registry-fetch": "^
|
|
70
|
+
"npm-registry-fetch": "^17.0.0",
|
|
71
71
|
"package-up": "^5.0.0",
|
|
72
72
|
"parse-gitignore": "^2.0.0",
|
|
73
73
|
"read-pkg": "^9.0.1",
|
|
@@ -78,6 +78,6 @@
|
|
|
78
78
|
},
|
|
79
79
|
"devDependencies": {
|
|
80
80
|
"@leverege/eslint-config-leverege": "^4.2.0",
|
|
81
|
-
"npm": "^10.
|
|
81
|
+
"npm": "^10.7.0"
|
|
82
82
|
}
|
|
83
83
|
}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
image:
|
|
2
|
-
tag: # v5.1
|
|
2
|
+
tag: # v5.12.1
|
|
3
3
|
|
|
4
4
|
config:
|
|
5
5
|
LOG_CONFIG: '{"type":"pino","level":"warn"}'
|
|
6
6
|
|
|
7
7
|
# CNPG overrides
|
|
8
8
|
# # stock pgsql
|
|
9
|
-
# MODEL_SQL_HOST: "db-
|
|
10
|
-
# PG_MODELS_HOST: "db-
|
|
9
|
+
# MODEL_SQL_HOST: "cnpg-db-psql-stack-rw.cnpg-operands"
|
|
10
|
+
# PG_MODELS_HOST: "cnpg-db-psql-stack-rw.cnpg-operands"
|
|
11
11
|
# # timescale
|
|
12
|
-
# PG_HOST: "db-
|
|
12
|
+
# PG_HOST: "cnpg-db-tsdb-basic-r.cnpg-operands"
|
|
13
13
|
|
|
14
14
|
autoscaling:
|
|
15
15
|
minReplicas: 3
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
image:
|
|
2
|
-
tag: #
|
|
2
|
+
tag: # v2.1.2
|
|
3
3
|
|
|
4
4
|
config:
|
|
5
5
|
LOG_CONFIG: '{"type":"pino","level":"warn"}'
|
|
@@ -7,4 +7,4 @@ config:
|
|
|
7
7
|
USE_MEMORY_CONTROLLER_CHECK_MODE : "false"
|
|
8
8
|
|
|
9
9
|
# CNPG override
|
|
10
|
-
# SQL_HOST: "db-
|
|
10
|
+
# SQL_HOST: "cnpg-db-psql-stack-rw.cnpg-operands" # vs postgres-postgresql
|
|
@@ -27,7 +27,7 @@ spec:
|
|
|
27
27
|
|
|
28
28
|
affinity:
|
|
29
29
|
# enablePodAntiAffinity: true
|
|
30
|
-
# topologyKey:
|
|
30
|
+
# topologyKey: kubernetes.io/hostname # default value
|
|
31
31
|
tolerations:
|
|
32
32
|
- key: "database"
|
|
33
33
|
operator: "Equal"
|
|
@@ -92,7 +92,7 @@ metadata:
|
|
|
92
92
|
namespace: cnpg-operands
|
|
93
93
|
spec:
|
|
94
94
|
# https://pkg.go.dev/github.com/robfig/cron#hdr-CRON_Expression_Format
|
|
95
|
-
schedule: "0 0
|
|
95
|
+
schedule: "0 0 0 * * *"
|
|
96
96
|
cluster:
|
|
97
97
|
name: cnpg-db-pgbench
|
|
98
98
|
method: volumeSnapshot
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
image:
|
|
2
|
-
tag: # v1.
|
|
2
|
+
tag: # v1.2.2
|
|
3
3
|
|
|
4
4
|
config:
|
|
5
5
|
LOG_CONFIG: '{"type":"pino","level":"warn"}'
|
|
@@ -8,4 +8,4 @@ config:
|
|
|
8
8
|
NETWORK_ID: 'set-me-in-values-local'
|
|
9
9
|
|
|
10
10
|
# CNPG override
|
|
11
|
-
# SQL_HOST: "db-
|
|
11
|
+
# SQL_HOST: "cnpg-db-psql-stack-rw.cnpg-operands" # vs postgres-postgresql
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
+
# migrations
|
|
2
|
+
# v1.2+ run => npm run sequelizeRunMigrations
|
|
3
|
+
#
|
|
1
4
|
image:
|
|
2
|
-
tag: # v1.1
|
|
5
|
+
tag: # v1.2.1
|
|
3
6
|
|
|
4
7
|
config:
|
|
5
8
|
LOG_CONFIG: '{"type":"pino","level":"warn"}'
|
|
@@ -9,4 +12,4 @@ config:
|
|
|
9
12
|
UPLOADER_LOCATION: "OVH:<GCE_REGION>"
|
|
10
13
|
|
|
11
14
|
# CNPG override
|
|
12
|
-
# SQL_HOST: "db-
|
|
15
|
+
# SQL_HOST: "cnpg-db-psql-stack-rw.cnpg-operands" # vs postgres-postgresql
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
image:
|
|
2
|
-
tag: # v2.
|
|
2
|
+
tag: # v2.2.2
|
|
3
3
|
|
|
4
4
|
config:
|
|
5
5
|
LOG_CONFIG: '{"type":"pino","level":"warn"}'
|
|
6
6
|
|
|
7
7
|
# CNPG override
|
|
8
|
-
# MODELS_SEQUELIZE_HOST: "db-
|
|
8
|
+
# MODELS_SEQUELIZE_HOST: "cnpg-db-psql-stack-rw.cnpg-operands" # vs postgres-postgresql
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
image:
|
|
2
|
-
tag: # v3.
|
|
2
|
+
tag: # v3.1.1
|
|
3
3
|
|
|
4
4
|
config:
|
|
5
5
|
LOG_CONFIG: '{"type":"pino","level":"warn"}'
|
|
6
6
|
|
|
7
7
|
# CNPG override
|
|
8
|
-
# SQL_HOST: "db-
|
|
8
|
+
# SQL_HOST: "cnpg-db-psql-stack-rw.cnpg-operands" # vs postgres-postgresql
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
nameOverride: transponder-dh
|
|
2
2
|
|
|
3
3
|
image:
|
|
4
|
-
tag: #
|
|
4
|
+
tag: # v5.2.0
|
|
5
5
|
|
|
6
6
|
config:
|
|
7
7
|
TRANSPONDER_RUN_MODE: "denseHistoryCombined"
|
|
@@ -10,11 +10,11 @@ config:
|
|
|
10
10
|
DENSE_HISTORY_TDB_CACHE_KEY_PREFIX: "timescale-dh"
|
|
11
11
|
DENSE_HISTORY_MIGRATE_PAGE_SIZE_LIMIT: "50"
|
|
12
12
|
|
|
13
|
-
# PG_HOST: "db-
|
|
14
|
-
PG_HOST: "db-
|
|
13
|
+
# PG_HOST: "cnpg-db-tsdb-dense-rw"
|
|
14
|
+
PG_HOST: "cnpg-db-tsdb-dense-pool-rw.cnpg-operands"
|
|
15
15
|
|
|
16
16
|
# password from secret
|
|
17
|
-
PG_PASSWORD_SECRET: "db-
|
|
17
|
+
PG_PASSWORD_SECRET: "cnpg-db-tsdb-dense-postgres-pw"
|
|
18
18
|
PG_PASSWORD_KEY: "password"
|
|
19
19
|
|
|
20
20
|
TRANSPORT_CONFIG: '{
|
|
@@ -7,14 +7,14 @@
|
|
|
7
7
|
nameOverride: transponder-tsdb
|
|
8
8
|
|
|
9
9
|
image:
|
|
10
|
-
tag: # v5.0
|
|
10
|
+
tag: # v5.2.0
|
|
11
11
|
|
|
12
12
|
config:
|
|
13
13
|
TRANSPONDER_RUN_MODE: "timescale"
|
|
14
14
|
LOG_CONFIG: '{"type":"pino","level":"warn"}'
|
|
15
15
|
|
|
16
16
|
# CNPG override
|
|
17
|
-
# PG_HOST: "db-
|
|
17
|
+
# PG_HOST: "cnpg-db-tsdb-basic-rw.cnpg-operands"
|
|
18
18
|
|
|
19
19
|
TRANSPORT_CONFIG: '{
|
|
20
20
|
"type": "pubsub",
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
[{"maxAgeSeconds": 3600, "method": ["*"], "origin": ["*"], "responseHeader": ["Content-Type"]}]
|
package/src/helmup.sh
CHANGED
|
@@ -24,7 +24,6 @@ PLATFORM=(
|
|
|
24
24
|
api-server
|
|
25
25
|
db-curator
|
|
26
26
|
emailer
|
|
27
|
-
fota-server
|
|
28
27
|
imagine
|
|
29
28
|
message-processor
|
|
30
29
|
messenger
|
|
@@ -38,6 +37,7 @@ PLATFORM=(
|
|
|
38
37
|
)
|
|
39
38
|
|
|
40
39
|
AUXILIARY=(
|
|
40
|
+
fota-server
|
|
41
41
|
geotile-server
|
|
42
42
|
overdose
|
|
43
43
|
pubsub-pulse
|
|
@@ -156,6 +156,37 @@ function createNamespaceIfNeeded() {
|
|
|
156
156
|
fi
|
|
157
157
|
}
|
|
158
158
|
|
|
159
|
+
function makeUniformBucketWithCors() {
|
|
160
|
+
local BUCKET_NAME="gs://${GCP_PROJECT_ID}-${1}"
|
|
161
|
+
printf "Creating/Updating bucket: `color g $BUCKET_NAME`\n"
|
|
162
|
+
gsutil ls -p $GCP_PROJECT_ID -b $BUCKET_NAME &> /dev/null
|
|
163
|
+
if [ "$?" -ne 0 ];
|
|
164
|
+
then
|
|
165
|
+
gsutil mb -l $GCE_REGION -p $GCP_PROJECT_ID $BUCKET_NAME &> /dev/null
|
|
166
|
+
[ "$?" -ne 0 ] && errorExit "failed to create the bucket: `color y $BUCKET_NAME`"
|
|
167
|
+
fi
|
|
168
|
+
CORS_JSON_FILE="$(build-tools --reporoot)/src/helmup-cors-for-buckets.json"
|
|
169
|
+
printf " Applying CORS policy\n"
|
|
170
|
+
gsutil cors set $CORS_JSON_FILE $BUCKET_NAME &> /dev/null
|
|
171
|
+
|
|
172
|
+
if [ "$2" == "PUBLIC" ];
|
|
173
|
+
then
|
|
174
|
+
printf " Making the bucket `color r PUBLIC`\n"
|
|
175
|
+
gsutil iam ch allUsers:objectViewer $BUCKET_NAME &> /dev/null
|
|
176
|
+
fi
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
function setupStackBuckets() {
|
|
180
|
+
makeUniformBucketWithCors resource-server
|
|
181
|
+
makeUniformBucketWithCors geotile-server PUBLIC
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
function doPlatormPreInstallChecks() {
|
|
185
|
+
# This is where we handle platform specific things that need to be setup,
|
|
186
|
+
# usuall once, and then promptly forgotten about.
|
|
187
|
+
setupStackBuckets
|
|
188
|
+
}
|
|
189
|
+
|
|
159
190
|
function bootstrapLocalSetup() {
|
|
160
191
|
SERVICE="$1"
|
|
161
192
|
[ -z "$SERVICE" ] && errorExit "bootstrapLocalSetup function requires a service name"
|
|
@@ -818,6 +849,7 @@ CATBACKUP
|
|
|
818
849
|
|
|
819
850
|
case "$SERVICE" in
|
|
820
851
|
"platform")
|
|
852
|
+
doPlatormPreInstallChecks
|
|
821
853
|
doInstall "${PLATFORM[@]}"
|
|
822
854
|
;;
|
|
823
855
|
|
|
@@ -900,6 +932,10 @@ CATBACKUP
|
|
|
900
932
|
monitoringHelp && exit 0
|
|
901
933
|
;;
|
|
902
934
|
|
|
935
|
+
"platform-buckets")
|
|
936
|
+
setupStackBuckets && exit 0
|
|
937
|
+
;;
|
|
938
|
+
|
|
903
939
|
"postgres")
|
|
904
940
|
bootstrapLocalSetup $SERVICE
|
|
905
941
|
;;
|