From 2308b9ae219afee52de8205d23e0ec8151a848a4 Mon Sep 17 00:00:00 2001 From: Anh Nguyen Date: Sat, 26 Aug 2023 13:21:04 +0700 Subject: [PATCH 1/3] Change from alpine to ubuntu in dockerfile.default --- Dockerfile.default | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/Dockerfile.default b/Dockerfile.default index c0eaec9..dbd7760 100644 --- a/Dockerfile.default +++ b/Dockerfile.default @@ -1,17 +1,24 @@ -FROM alpine AS build +FROM ubuntu:22.04 AS build -RUN apk add --update alpine-sdk boost-dev cmake asio-dev +ENV DEBIAN_FRONTEND=noninteractive -ADD ./ /turbopilot/ +# inlude kitware apt repo to allow us to grab latest cmake +RUN apt-get update && apt-get install -y ca-certificates gpg wget +RUN wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | gpg --dearmor - | tee /usr/share/keyrings/kitware-archive-keyring.gpg >/dev/null +RUN echo 'deb [signed-by=/usr/share/keyrings/kitware-archive-keyring.gpg] https://apt.kitware.com/ubuntu/ jammy main' | tee /etc/apt/sources.list.d/kitware.list >/dev/null + +RUN apt-get update && apt-get install -y build-essential cmake libboost-dev libboost-thread-dev + +ADD ./ /turbopilot RUN mkdir /turbopilot/build WORKDIR /turbopilot/build -RUN cmake -D GGML_STATIC=ON .. +RUN cmake -DGGML_OPENBLAS=ON .. RUN make turbopilot -FROM alpine AS runtime +FROM ubuntu:22.04 AS runtime WORKDIR /app From 20b1460bd8377d5251f38b744d7aa49826df9f53 Mon Sep 17 00:00:00 2001 From: Anh Nguyen Date: Sat, 26 Aug 2023 14:21:18 +0700 Subject: [PATCH 2/3] Using GGML_STATIC --- Dockerfile.default | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile.default b/Dockerfile.default index dbd7760..38082d6 100644 --- a/Dockerfile.default +++ b/Dockerfile.default @@ -15,7 +15,7 @@ RUN mkdir /turbopilot/build WORKDIR /turbopilot/build -RUN cmake -DGGML_OPENBLAS=ON .. +RUN cmake -D GGML_STATIC=ON .. RUN make turbopilot FROM ubuntu:22.04 AS runtime From 3e37c4bb7c270241c4b4ebee5b9ef14a9cf37146 Mon Sep 17 00:00:00 2001 From: Anh Nguyen Date: Sat, 26 Aug 2023 14:27:27 +0700 Subject: [PATCH 3/3] Update cmake command --- Dockerfile.default | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile.default b/Dockerfile.default index 38082d6..54b39e7 100644 --- a/Dockerfile.default +++ b/Dockerfile.default @@ -15,7 +15,7 @@ RUN mkdir /turbopilot/build WORKDIR /turbopilot/build -RUN cmake -D GGML_STATIC=ON .. +RUN cmake .. RUN make turbopilot FROM ubuntu:22.04 AS runtime