From f3930e2d90ddd47c3ce98186a49269ef218152aa Mon Sep 17 00:00:00 2001 From: Jayson Reis Date: Wed, 20 Nov 2024 13:42:36 +0100 Subject: [PATCH] fix: Make sure that images can be built on arm64 This happens because pymssql does not have wheels for arm64 --- docker/dockerfiles/backend.Dockerfile | 2 ++ docker/dockerfiles/worker.Dockerfile | 2 +- docker/dockerfiles/x2text.Dockerfile | 5 ++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/docker/dockerfiles/backend.Dockerfile b/docker/dockerfiles/backend.Dockerfile index 2522113c8..943d82f9a 100644 --- a/docker/dockerfiles/backend.Dockerfile +++ b/docker/dockerfiles/backend.Dockerfile @@ -23,6 +23,8 @@ RUN apt-get update; \ apt-get --no-install-recommends install -y \ # unstract sdk build-essential libmagic-dev pandoc pkg-config tesseract-ocr \ + # pymssql + freetds-dev libssl-dev libkrb5-dev \ # git url git; \ apt-get clean && rm -rf /var/lib/apt/lists/* /var/cache/apt/archives/*; \ diff --git a/docker/dockerfiles/worker.Dockerfile b/docker/dockerfiles/worker.Dockerfile index 8e49fddb0..3790b83f6 100644 --- a/docker/dockerfiles/worker.Dockerfile +++ b/docker/dockerfiles/worker.Dockerfile @@ -13,7 +13,7 @@ ENV BUILD_PACKAGES_PATH unstract ENV PDM_VERSION 2.16.1 RUN apt-get update \ - && apt-get --no-install-recommends install -y docker \ + && apt-get --no-install-recommends install -y docker build-essential pkg-config freetds-dev libssl-dev libkrb5-dev \ && apt-get clean && rm -rf /var/lib/apt/lists/* /var/cache/apt/archives/* \ \ && pip install --no-cache-dir -U pip pdm~=${PDM_VERSION} diff --git a/docker/dockerfiles/x2text.Dockerfile b/docker/dockerfiles/x2text.Dockerfile index dc5f3eae6..7f69c648f 100644 --- a/docker/dockerfiles/x2text.Dockerfile +++ b/docker/dockerfiles/x2text.Dockerfile @@ -10,7 +10,10 @@ ENV PYTHONUNBUFFERED 1 ENV BUILD_CONTEXT_PATH x2text-service ENV PDM_VERSION 2.16.1 -RUN pip install --no-cache-dir -U pip pdm~=${PDM_VERSION}; \ +RUN apt-get update; \ + apt-get --no-install-recommends install -y \ + build-essential pkg-config && \ + pip install --no-cache-dir -U pip pdm~=${PDM_VERSION}; \ \ # Creates a non-root user with an explicit UID and adds permission to access the /app folder # For more info, please refer to https://aka.ms/vscode-docker-python-configure-containers