From 18c62626ebb0afea84b32e2924a6360b27d10bb8 Mon Sep 17 00:00:00 2001 From: Danielle Mayabb Date: Thu, 8 Feb 2024 15:08:13 -0800 Subject: [PATCH] docker: Add prod dockerfile for api --- docker/prod.api.Dockerfile | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 docker/prod.api.Dockerfile diff --git a/docker/prod.api.Dockerfile b/docker/prod.api.Dockerfile new file mode 100644 index 000000000..850e53915 --- /dev/null +++ b/docker/prod.api.Dockerfile @@ -0,0 +1,17 @@ +FROM debian:bullseye-slim + +RUN apt update && apt -y install python3 python3-pip openssh-client + +WORKDIR /api + +COPY ./api/pyproject.toml /api/pyproject.toml + +RUN python3 -m pip install --upgrade pip +RUN pip install --no-cache-dir . +RUN pip install .[dev] + +COPY ./api /api + +EXPOSE 8555 + +CMD ["uvicorn", "main:app","--proxy-headers", "--reload", "--host", "0.0.0.0", "--port", "8555"]