split dockerfile into main & tools

This commit is contained in:
Bernat Vadell 2023-03-14 15:46:03 +01:00
parent 6d9ad1058b
commit 9959b1f374
2 changed files with 20 additions and 8 deletions

18
.devops/main.Dockerfile Normal file
View file

@ -0,0 +1,18 @@
ARG UBUNTU_VERSION=22.04
FROM ubuntu:$UBUNTU_VERSION as build
RUN apt-get update && \
apt-get install -y build-essential
WORKDIR /app
COPY . .
RUN make
FROM ubuntu:$UBUNTU_VERSION as runtime
COPY --from=build /app/main /main
ENTRYPOINT [ "/main" ]

View file

@ -10,12 +10,6 @@ RUN pip install --upgrade pip setuptools wheel \
WORKDIR /app
COPY . .
COPY ./convert-pth-to-ggml.py .
RUN make
FROM ubuntu:$UBUNTU_VERSION as runtime
COPY --from=build /app/main /main
ENTRYPOINT [ "/main" ]
ENTRYPOINT ["python3", "convert-pth-to-ggml.py"]