diff --git a/Dockerfile b/Dockerfile index cf605e0..4827450 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,14 @@ -FROM python:3.10.6 -COPY requirements.txt /app/ +FROM python:3.10.6-slim as base +LABEL maintainer="salman@scaleoutsystems.com" WORKDIR /app -RUN pip install -e git+https://github.com/scaleoutsystems/fedn.git@develop#egg=fedn\&subdirectory=fedn -RUN pip install -r requirements.txt +COPY requirements.txt . +RUN apt-get update \ + && apt-get install --no-install-recommends -y git \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/* \ + && pip install -e git+https://github.com/scaleoutsystems/fedn.git@develop#egg=fedn\&subdirectory=fedn \ + && pip install --no-cache-dir -r requirements.txt + + +FROM python:3.10.6-slim as build +COPY --from=base /usr/local/lib/python3.10/site-packages/ /usr/local/lib/python3.10/site-packages/