diff --git a/Dockerfile b/Dockerfile index 2a4d3959170..0782d122b98 100644 --- a/Dockerfile +++ b/Dockerfile @@ -43,9 +43,16 @@ RUN apk add --no-cache -t build-dependencies \ tini \ uwsgi \ uwsgi-python3 \ - brotli \ - && pip3 install --break-system-packages --no-cache -r requirements.txt \ - && apk del build-dependencies \ + brotli + +# For 32bit arm architecture install pydantic from the alpine repos instead of requirements.txt +ARG TARGETARCH +RUN if [ "$TARGETARCH" = "arm" ]; then \ + apk add --no-cache py3-pydantic && pip install --no-cache --break-system-packages -r <(grep -v '^pydantic' requirements.txt); \ + else \ + pip install --no-cache --break-system-packages -r requirements.txt; \ + fi + RUN apk del build-dependencies \ && rm -rf /root/.cache COPY --chown=searxng:searxng dockerfiles ./dockerfiles