Skip to content

Commit a32df74

Browse files
fix: engine command (#178)
1 parent 1cac238 commit a32df74

File tree

2 files changed

+19
-7
lines changed

2 files changed

+19
-7
lines changed

charts/codefresh/files/updateSystemReImages.sh

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,13 @@ function updateRESpec {
3535
}
3636
}
3737
)"
38+
mongosh "$MONGO_URI_RE_MANAGER" --tls --tlsCertificateKeyFile /etc/ssl/mongodb/ca.pem --tlsAllowInvalidHostnames --tlsAllowInvalidCertificates --eval "db.getCollection('runtime-environment').updateOne(
39+
{'metadata.name': '$1'},
40+
{ \$set: {
41+
\"runtimeScheduler.command\": [\"node\", \"dist/server/index.js\"]
42+
}
43+
}
44+
)"
3845
else
3946
mongosh "$MONGO_URI_RE_MANAGER" --eval "db.getCollection('runtime-environment').updateOne(
4047
{'metadata.name': '$1'},
@@ -57,6 +64,13 @@ function updateRESpec {
5764
}
5865
}
5966
)"
67+
mongosh "$MONGO_URI_RE_MANAGER" --eval "db.getCollection('runtime-environment').updateOne(
68+
{'metadata.name': '$1'},
69+
{ \$set: {
70+
\"runtimeScheduler.command\": [\"node\", \"dist/server/index.js\"]
71+
}
72+
}
73+
)"
6074
fi
6175
}
6276

@@ -65,4 +79,4 @@ disableMongoTelemetry
6579
for re in ${DEFAULT_RE_NAMES[@]}; do
6680
echo "Updating the runtime $re"
6781
updateRESpec $re
68-
done
82+
done

charts/codefresh/templates/configmaps/runtimeEnvironments.json.tpl

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,8 @@
3131
},
3232
"image": "{{ include "codefresh.buildImageName" (dict "registry" .Values.global.imageRegistry "imageFullName" .Values.runtimeImages.ENGINE_IMAGE) }}",
3333
"command": [
34-
"npm",
35-
"run",
36-
"start"
34+
"node",
35+
"dist/server/index.js"
3736
],
3837
"envVars": {
3938
{{- if .Values.global.env }}
@@ -111,9 +110,8 @@
111110
"runtimeScheduler": {
112111
"image": "{{ include "codefresh.buildImageName" (dict "registry" .Values.global.imageRegistry "imageFullName" .Values.runtimeImages.ENGINE_IMAGE) }}",
113112
"command": [
114-
"npm",
115-
"run",
116-
"start"
113+
"node",
114+
"dist/server/index.js"
117115
],
118116
"envVars": {
119117
"CONTAINER_LOGGER_SHOW_PROGRESS": "true",

0 commit comments

Comments
 (0)