2024-01-28 07:55:31 +00:00
|
|
|
ARG UBUNTU_VERSION=22.04
|
|
|
|
|
|
|
|
FROM ubuntu:$UBUNTU_VERSION as build
|
|
|
|
|
|
|
|
RUN apt-get update && \
|
2024-04-03 17:56:37 +00:00
|
|
|
apt-get install -y build-essential git libcurl4-openssl-dev
|
2024-01-28 07:55:31 +00:00
|
|
|
|
|
|
|
WORKDIR /app
|
|
|
|
|
|
|
|
COPY . .
|
|
|
|
|
2024-04-03 17:56:37 +00:00
|
|
|
ENV LLAMA_CURL=1
|
|
|
|
|
2024-05-30 20:32:38 +00:00
|
|
|
RUN make -j$(nproc)
|
2024-01-28 07:55:31 +00:00
|
|
|
|
|
|
|
FROM ubuntu:$UBUNTU_VERSION as runtime
|
|
|
|
|
2024-04-03 17:56:37 +00:00
|
|
|
RUN apt-get update && \
|
|
|
|
apt-get install -y libcurl4-openssl-dev
|
|
|
|
|
2024-01-28 07:55:31 +00:00
|
|
|
COPY --from=build /app/server /server
|
|
|
|
|
|
|
|
ENV LC_ALL=C.utf8
|
|
|
|
|
|
|
|
ENTRYPOINT [ "/server" ]
|