Skip to content

Commit c4d6ef3

Browse files
committed
fix of SAST-found /tmp hotspot
1 parent 89c104a commit c4d6ef3

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

backend/app/services/pod_manifest_builder.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,9 @@ def build(self) -> Dict[str, Any]:
4848
"image": self.image,
4949
"imagePullPolicy": "IfNotPresent",
5050
"command": self.command,
51+
"env": [
52+
{"name": "TMPDIR", "value": "/writeable"}
53+
],
5154
"resources": {
5255
"limits": {"cpu": self.pod_cpu_limit,
5356
"memory": self.pod_memory_limit},
@@ -57,7 +60,7 @@ def build(self) -> Dict[str, Any]:
5760
"volumeMounts": [
5861
{"name": "script-volume", "mountPath": "/scripts", "readOnly": True},
5962
{"name": "entrypoint-vol", "mountPath": "/entry", "readOnly": True},
60-
{"name": "writable-tmp", "mountPath": "/tmp"}
63+
{"name": "writable-tmp", "mountPath": "/writeable"}
6164
],
6265
"terminationMessagePolicy": "FallbackToLogsOnError",
6366
"securityContext": {

0 commit comments

Comments
 (0)