Add --break-system-packages so pip works on system Python

This commit is contained in:
Abhilash Raj
2023-12-26 10:47:22 +00:00
parent 354b346160
commit f3bca54120
6 changed files with 16 additions and 16 deletions

View File

@@ -13,8 +13,8 @@ RUN --mount=type=cache,target=/root/.cache \
# Mailman html to plaintext conversion uses lynx. # Mailman html to plaintext conversion uses lynx.
# psutil needs linux-headers to compile on musl c library. # psutil needs linux-headers to compile on musl c library.
&& apk add --no-cache bash su-exec postgresql-client mysql-client curl python3 py3-pip linux-headers py-cryptography mariadb-connector-c lynx tzdata \ && apk add --no-cache bash su-exec postgresql-client mysql-client curl python3 py3-pip linux-headers py-cryptography mariadb-connector-c lynx tzdata \
&& python3 -m pip install -U pip setuptools wheel \ && python3 -m pip install --break-system-packages -U pip setuptools wheel \
&& python3 -m pip install psycopg2 \ && python3 -m pip install --break-system-packages psycopg2 \
gunicorn==19.9.0 \ gunicorn==19.9.0 \
pymysql \ pymysql \
-r /tmp/requirements.txt \ -r /tmp/requirements.txt \

View File

@@ -14,8 +14,8 @@ RUN --mount=type=cache,target=/root/.cache \
postgresql-dev git libffi-dev g++ \ postgresql-dev git libffi-dev g++ \
&& apk add --no-cache bash su-exec postgresql-client mysql-client \ && apk add --no-cache bash su-exec postgresql-client mysql-client \
curl python3 py3-pip linux-headers py-cryptography mariadb-connector-c tzdata \ curl python3 py3-pip linux-headers py-cryptography mariadb-connector-c tzdata \
&& python3 -m pip install -U psycopg2 pymysql setuptools wheel \ && python3 -m pip install -U --break-system-packages psycopg2 pymysql setuptools wheel \
&& python3 -m pip install \ && python3 -m pip install --break-system-packages \
git+https://gitlab.com/mailman/mailman \ git+https://gitlab.com/mailman/mailman \
git+https://gitlab.com/mailman/mailman-hyperkitty \ git+https://gitlab.com/mailman/mailman-hyperkitty \
gunicorn==19.9.0 \ gunicorn==19.9.0 \

View File

@@ -11,8 +11,8 @@ RUN --mount=type=cache,target=/root/.cache \
&& apk add --no-cache --virtual .mailman-rundeps bash sassc tzdata \ && apk add --no-cache --virtual .mailman-rundeps bash sassc tzdata \
postgresql-client mysql-client py3-mysqlclient curl mailcap gettext \ postgresql-client mysql-client py3-mysqlclient curl mailcap gettext \
python3 py3-pip libffi libuuid pcre-dev py-cryptography \ python3 py3-pip libffi libuuid pcre-dev py-cryptography \
&& python3 -m pip install -U 'Django<4.2' pip setuptools wheel \ && python3 -m pip install --break-system-packages -U 'Django<4.2' pip setuptools wheel \
&& python3 -m pip install postorius==1.3.7 \ && python3 -m pip install --break-system-packages postorius==1.3.7 \
uwsgi \ uwsgi \
'psycopg2<2.9' \ 'psycopg2<2.9' \
dj-database-url \ dj-database-url \

View File

@@ -15,8 +15,8 @@ RUN --mount=type=cache,target=/root/.cache \
&& apk add --no-cache --virtual .mailman-rundeps bash sassc tzdata \ && apk add --no-cache --virtual .mailman-rundeps bash sassc tzdata \
postgresql-client mysql-client py3-mysqlclient curl mailcap \ postgresql-client mysql-client py3-mysqlclient curl mailcap \
python3 py3-pip libffi gettext py-cryptography \ python3 py3-pip libffi gettext py-cryptography \
&& python3 -m pip install -U pip setuptools wheel \ && python3 -m pip install --break-system-packages -U pip setuptools wheel \
&& python3 -m pip install -U \ && python3 -m pip install --break-system-packages -U \
git+https://gitlab.com/mailman/mailmanclient \ git+https://gitlab.com/mailman/mailmanclient \
git+https://gitlab.com/mailman/postorius \ git+https://gitlab.com/mailman/postorius \
uwsgi \ uwsgi \
@@ -25,8 +25,8 @@ RUN --mount=type=cache,target=/root/.cache \
mysqlclient \ mysqlclient \
typing \ typing \
django-utils-six \ django-utils-six \
&& python3 -m pip install -U 'Django<3.2' \ && python3 -m pip install --break-system-packages -U 'Django<3.2' \
&& python3 -m pip install -U \ && python3 -m pip install --break-system-packages -U \
git+https://gitlab.com/mailman/django-mailman3 \ git+https://gitlab.com/mailman/django-mailman3 \
&& apk del .build-deps \ && apk del .build-deps \
&& addgroup -S mailman \ && addgroup -S mailman \

View File

@@ -14,8 +14,8 @@ RUN --mount=type=cache,target=/root/.cache \
&& apk add --no-cache --virtual .mailman-rundeps bash sassc tzdata \ && apk add --no-cache --virtual .mailman-rundeps bash sassc tzdata \
postgresql-client mysql-client py3-mysqlclient curl mailcap gettext \ postgresql-client mysql-client py3-mysqlclient curl mailcap gettext \
python3 py3-pip xapian-core xapian-bindings-python3 libffi pcre-dev py-cryptography \ python3 py3-pip xapian-core xapian-bindings-python3 libffi pcre-dev py-cryptography \
&& python3 -m pip install -U 'Django<4.2' pip setuptools wheel \ && python3 -m pip install --break-system-packages -U 'Django<4.2' pip setuptools wheel \
&& pip install -r /tmp/requirements.txt \ && pip install --break-system-packages -r /tmp/requirements.txt \
whoosh \ whoosh \
uwsgi \ uwsgi \
psycopg2 \ psycopg2 \

View File

@@ -16,8 +16,8 @@ RUN --mount=type=cache,target=/root/.cache \
&& apk add --no-cache --virtual .mailman-rundeps bash sassc pcre-dev tzdata \ && apk add --no-cache --virtual .mailman-rundeps bash sassc pcre-dev tzdata \
python3 py3-pip postgresql-client mysql-client py3-mysqlclient \ python3 py3-pip postgresql-client mysql-client py3-mysqlclient \
curl mailcap xapian-core xapian-bindings-python3 libffi gettext py-cryptography \ curl mailcap xapian-core xapian-bindings-python3 libffi gettext py-cryptography \
&& python3 -m pip install -U pip setuptools wheel \ && python3 -m pip install --break-system-packages -U pip setuptools wheel \
&& python3 -m pip install -U \ && python3 -m pip install --break-system-packages -U \
git+https://gitlab.com/mailman/mailmanclient \ git+https://gitlab.com/mailman/mailmanclient \
git+https://gitlab.com/mailman/postorius \ git+https://gitlab.com/mailman/postorius \
git+https://gitlab.com/mailman/hyperkitty \ git+https://gitlab.com/mailman/hyperkitty \
@@ -32,8 +32,8 @@ RUN --mount=type=cache,target=/root/.cache \
tzdata \ tzdata \
diskcache \ diskcache \
django-utils-six \ django-utils-six \
&& python3 -m pip install -U 'Django<4.2' \ && python3 -m pip install --break-system-packages -U 'Django<4.2' \
&& python3 -m pip install -U \ && python3 -m pip install --break-system-packages -U \
git+https://gitlab.com/mailman/django-mailman3 \ git+https://gitlab.com/mailman/django-mailman3 \
&& apk del .build-deps \ && apk del .build-deps \
&& addgroup -S mailman \ && addgroup -S mailman \