Skip to content

Commit 80e763f

Browse files
author
Max Azatian
committed
- fix of trivy errors (docker scan)
- fix of bandit errors (sec scan)
1 parent b89a916 commit 80e763f

File tree

3 files changed

+3
-7
lines changed

3 files changed

+3
-7
lines changed

backend/Dockerfile

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,7 @@ RUN apt-get update && apt-get upgrade -y liblzma-dev liblzma5 xz-utils && \
66
apt-get install -y libsnappy-dev && \
77
rm -rf /var/lib/apt/lists/*
88

9-
# Install kubectl v1.32.6 (temporary pin to avoid CVE-2025-47907 until v1.33.5+ is released)
10-
# Note: v1.32 series is still supported and should work with most K8s clusters
11-
# TODO: Update to latest stable once kubectl is rebuilt with Go 1.24.6+
12-
RUN wget -q "https://dl.k8s.io/release/v1.32.6/bin/linux/amd64/kubectl" -O /usr/local/bin/kubectl && \
13-
chmod +x /usr/local/bin/kubectl
9+
## Remove kubectl from runtime image: rely on Python client only
1410

1511
# Install Python dependencies
1612
COPY requirements.txt .

backend/app/services/k8s_worker/pod_builder.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ def _build_container(self, command: CreatePodCommandEvent) -> k8s_client.V1Conta
8080
k8s_client.V1VolumeMount(name="script-volume", mount_path="/scripts", read_only=True),
8181
k8s_client.V1VolumeMount(name="entrypoint-volume", mount_path="/entry", read_only=True),
8282
k8s_client.V1VolumeMount(name="output-volume", mount_path="/output"),
83-
k8s_client.V1VolumeMount(name="tmp-volume", mount_path="/tmp")
83+
k8s_client.V1VolumeMount(name="tmp-volume", mount_path="/tmp") # nosec B108: K8s EmptyDir mounted inside container; not host /tmp
8484
],
8585
resources=k8s_client.V1ResourceRequirements(
8686
requests={"cpu": cpu_request, "memory": memory_request},

backend/requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ types-confluent-kafka==1.3.6
114114
typing_extensions==4.12.2
115115
urllib3==2.2.3
116116
uvicorn==0.34.2
117-
gunicorn==22.0.0
117+
gunicorn==23.0.0
118118
websocket-client==1.8.0
119119
Werkzeug==3.0.4
120120
wrapt==1.16.0

0 commit comments

Comments
 (0)