From 3ad1283765c6406425060bdb350c4b7a4a1f13ea Mon Sep 17 00:00:00 2001 From: Cedric Evers <12080057+CeEv@users.noreply.github.com> Date: Wed, 31 Jul 2024 12:02:06 +0200 Subject: [PATCH 1/3] Change --max-old-space-size for tldraw deployment, depend on the pod deployment changes as temporary solution. --- .../schulcloud-server-core/templates/tldraw-deployment.yml.j2 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ansible/roles/schulcloud-server-core/templates/tldraw-deployment.yml.j2 b/ansible/roles/schulcloud-server-core/templates/tldraw-deployment.yml.j2 index f6f8783dc13..f2eb3d34675 100644 --- a/ansible/roles/schulcloud-server-core/templates/tldraw-deployment.yml.j2 +++ b/ansible/roles/schulcloud-server-core/templates/tldraw-deployment.yml.j2 @@ -55,6 +55,9 @@ spec: - containerPort: 9090 name: api-metrics protocol: TCP + env: + - name: NODE_OPTIONS + value "--max-old-space-size=4096" envFrom: - configMapRef: name: api-configmap From 050728465192d2651bfddbb8c3b70c6d6de8d21b Mon Sep 17 00:00:00 2001 From: Cedric Evers <12080057+CeEv@users.noreply.github.com> Date: Wed, 31 Jul 2024 12:58:32 +0200 Subject: [PATCH 2/3] Change order to override the envFrom NODE_OPTIONS --- .../templates/tldraw-deployment.yml.j2 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ansible/roles/schulcloud-server-core/templates/tldraw-deployment.yml.j2 b/ansible/roles/schulcloud-server-core/templates/tldraw-deployment.yml.j2 index f2eb3d34675..09ce4c6e8d7 100644 --- a/ansible/roles/schulcloud-server-core/templates/tldraw-deployment.yml.j2 +++ b/ansible/roles/schulcloud-server-core/templates/tldraw-deployment.yml.j2 @@ -55,9 +55,6 @@ spec: - containerPort: 9090 name: api-metrics protocol: TCP - env: - - name: NODE_OPTIONS - value "--max-old-space-size=4096" envFrom: - configMapRef: name: api-configmap @@ -67,6 +64,9 @@ spec: name: tldraw-server-secret - secretRef: name: api-files-secret + env: + - name: NODE_OPTIONS + value "--max-old-space-size=4096" command: ['npm', 'run', 'nest:start:tldraw:prod'] resources: limits: From 7e82a471cca1b6e06095cf1ecc5afefd4acc09d0 Mon Sep 17 00:00:00 2001 From: Cedric Evers <12080057+CeEv@users.noreply.github.com> Date: Wed, 31 Jul 2024 13:12:12 +0200 Subject: [PATCH 3/3] Add missing points --- .../schulcloud-server-core/templates/tldraw-deployment.yml.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ansible/roles/schulcloud-server-core/templates/tldraw-deployment.yml.j2 b/ansible/roles/schulcloud-server-core/templates/tldraw-deployment.yml.j2 index 09ce4c6e8d7..56cf6d540c8 100644 --- a/ansible/roles/schulcloud-server-core/templates/tldraw-deployment.yml.j2 +++ b/ansible/roles/schulcloud-server-core/templates/tldraw-deployment.yml.j2 @@ -66,7 +66,7 @@ spec: name: api-files-secret env: - name: NODE_OPTIONS - value "--max-old-space-size=4096" + value: "--max-old-space-size=4096" command: ['npm', 'run', 'nest:start:tldraw:prod'] resources: limits: