From 0918e5b8069d2a3e51fca4bccef97102b94bc9e8 Mon Sep 17 00:00:00 2001 From: snyk-bot Date: Sun, 14 Apr 2024 18:06:21 +0000 Subject: [PATCH] fix: Dockerfile to reduce vulnerabilities The following vulnerabilities are fixed with an upgrade: - https://snyk.io/vuln/SNYK-DEBIAN12-UTILLINUX-6508631 - https://snyk.io/vuln/SNYK-DEBIAN12-UTILLINUX-6508631 - https://snyk.io/vuln/SNYK-DEBIAN12-UTILLINUX-6508631 - https://snyk.io/vuln/SNYK-DEBIAN12-UTILLINUX-6508631 - https://snyk.io/vuln/SNYK-DEBIAN12-ZLIB-6008963 --- Dockerfile | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) mode change 120000 => 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile deleted file mode 120000 index f173f1a..0000000 --- a/Dockerfile +++ /dev/null @@ -1 +0,0 @@ -Dockerfile.c12e-ci.cortex-python-lib \ No newline at end of file diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..e5f6964 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,14 @@ +FROM python:3.13.0a6-slim +ENV ISTIO_QUIT_API=http://localhost:15020 +ENV ENVOY_ADMIN_API=http://localhost:15000 +COPY --from=c12e/scuttle:latest /scuttle /bin/scuttle +COPY ./cortex /tmp/src/cortex +COPY ./scripts/entrypoint.sh /entrypoint.sh +COPY setup.py README.md /tmp/src/ +RUN cd /tmp/src\ + && pip install . flask fastapi uvicorn typing\ + && echo "default:x:1001:0:Default Application User:/app:/sbin/nologin" >> /etc/passwd\ + && rm -r /tmp/src +USER default +WORKDIR /app +ENTRYPOINT ["/bin/bash", "/entrypoint.sh"]