From 8d6908d663c30058fda0026261d06696ff20b7ec Mon Sep 17 00:00:00 2001 From: Alan Jean Date: Tue, 31 Jan 2023 19:56:13 +0400 Subject: [PATCH] =?UTF-8?q?chore(inference):=20follow=20the=20pattern=20of?= =?UTF-8?q?=20splitting=20base-env=20and=20prod=20stage=20=F0=9F=90=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docker/inference/Dockerfile.text-client | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/docker/inference/Dockerfile.text-client b/docker/inference/Dockerfile.text-client index 1a4c4ae0..23a54abe 100644 --- a/docker/inference/Dockerfile.text-client +++ b/docker/inference/Dockerfile.text-client @@ -19,7 +19,7 @@ RUN --mount=type=cache,target=/var/cache/pip \ -FROM python:3.10-alpine3.17 as dev +FROM python:3.10-alpine3.17 as base-env ARG APP_USER ARG APP_RELATIVE_PATH @@ -43,4 +43,8 @@ COPY --chown="${APP_USER}:${APP_USER}" --from=build /build/lib COPY --chown="${APP_USER}:${APP_USER}" ./${APP_RELATIVE_PATH}/__main__.py . + +FROM base-env as prod + + CMD python3 __main__.py --backend-url "${BACKEND_URL}"