From 5f93ff04a939d7c1d421ffebcb55147f48bc13a6 Mon Sep 17 00:00:00 2001 From: FreddleSpl0it <75116288+FreddleSpl0it@users.noreply.github.com> Date: Fri, 23 May 2025 09:47:25 +0200 Subject: [PATCH] Add psutil module for bootstrapping --- data/Dockerfiles/clamd/Dockerfile | 10 +++++++++- data/Dockerfiles/dovecot/Dockerfile | 11 ++++++----- data/Dockerfiles/mariadb/Dockerfile | 3 ++- data/Dockerfiles/nginx/Dockerfile | 8 ++++++++ data/Dockerfiles/phpfpm/Dockerfile | 8 ++++++++ data/Dockerfiles/postfix/Dockerfile | 3 ++- data/Dockerfiles/rspamd/Dockerfile | 3 ++- data/Dockerfiles/sogo/Dockerfile | 3 ++- 8 files changed, 39 insertions(+), 10 deletions(-) diff --git a/data/Dockerfiles/clamd/Dockerfile b/data/Dockerfiles/clamd/Dockerfile index b7908502c..212f393aa 100644 --- a/data/Dockerfiles/clamd/Dockerfile +++ b/data/Dockerfiles/clamd/Dockerfile @@ -94,7 +94,15 @@ RUN apk upgrade --no-cache \ install -d -m 755 -g "clamav" -o "clamav" "/var/log/clamav" && \ chown -R clamav:clamav /var/lib/clamav -RUN pip install --break-system-packages \ +RUN apk add --no-cache --virtual .build-deps \ + gcc \ + musl-dev \ + python3-dev \ + linux-headers \ + && pip install --break-system-packages psutil \ + && apk del .build-deps + +RUN pip install --break-system-packages \ mysql-connector-python \ jinja2 \ redis \ diff --git a/data/Dockerfiles/dovecot/Dockerfile b/data/Dockerfiles/dovecot/Dockerfile index e4ca40b32..66ba8ef58 100644 --- a/data/Dockerfiles/dovecot/Dockerfile +++ b/data/Dockerfiles/dovecot/Dockerfile @@ -87,11 +87,11 @@ RUN addgroup -g 5000 vmail \ perl-proc-processtable \ perl-app-cpanminus \ procps \ - python3 py3-pip \ - py3-mysqlclient \ + python3 py3-pip python3-dev \ py3-html2text \ - py3-jinja2 \ - py3-redis \ + linux-headers \ + musl-dev \ + gcc \ redis \ syslog-ng \ syslog-ng-redis \ @@ -119,7 +119,8 @@ RUN pip install --break-system-packages \ mysql-connector-python \ jinja2 \ redis \ - dnspython + dnspython \ + psutil COPY data/Dockerfiles/bootstrap /bootstrap diff --git a/data/Dockerfiles/mariadb/Dockerfile b/data/Dockerfiles/mariadb/Dockerfile index 6662f1035..c499e6b97 100644 --- a/data/Dockerfiles/mariadb/Dockerfile +++ b/data/Dockerfiles/mariadb/Dockerfile @@ -15,7 +15,8 @@ RUN pip install \ mysql-connector-python \ jinja2 \ redis \ - dnspython + dnspython \ + psutil COPY data/Dockerfiles/bootstrap /bootstrap diff --git a/data/Dockerfiles/nginx/Dockerfile b/data/Dockerfiles/nginx/Dockerfile index ea7127c5d..07d888282 100644 --- a/data/Dockerfiles/nginx/Dockerfile +++ b/data/Dockerfiles/nginx/Dockerfile @@ -7,6 +7,14 @@ RUN apk add --no-cache nginx \ python3 py3-pip \ supervisor +RUN apk add --no-cache --virtual .build-deps \ + gcc \ + musl-dev \ + python3-dev \ + linux-headers \ + && pip install --break-system-packages psutil \ + && apk del .build-deps + RUN pip install --break-system-packages \ mysql-connector-python \ jinja2 \ diff --git a/data/Dockerfiles/phpfpm/Dockerfile b/data/Dockerfiles/phpfpm/Dockerfile index 3432b092f..0403bee5d 100644 --- a/data/Dockerfiles/phpfpm/Dockerfile +++ b/data/Dockerfiles/phpfpm/Dockerfile @@ -108,6 +108,14 @@ RUN apk add -U --no-cache autoconf \ pcre-dev \ zlib-dev +RUN apk add --no-cache --virtual .build-deps \ + gcc \ + musl-dev \ + python3-dev \ + linux-headers \ + && pip install --break-system-packages psutil \ + && apk del .build-deps + RUN pip install --break-system-packages \ mysql-connector-python \ jinja2 \ diff --git a/data/Dockerfiles/postfix/Dockerfile b/data/Dockerfiles/postfix/Dockerfile index f0100f9a6..3bcdc6dd8 100644 --- a/data/Dockerfiles/postfix/Dockerfile +++ b/data/Dockerfiles/postfix/Dockerfile @@ -44,7 +44,8 @@ RUN pip install --break-system-packages \ mysql-connector-python \ jinja2 \ redis \ - dnspython + dnspython \ + psutil COPY data/Dockerfiles/bootstrap /bootstrap COPY data/Dockerfiles/postfix/supervisord.conf /etc/supervisor/supervisord.conf diff --git a/data/Dockerfiles/rspamd/Dockerfile b/data/Dockerfiles/rspamd/Dockerfile index 153aa3966..8f2423a3c 100644 --- a/data/Dockerfiles/rspamd/Dockerfile +++ b/data/Dockerfiles/rspamd/Dockerfile @@ -34,7 +34,8 @@ RUN pip install --break-system-packages \ mysql-connector-python \ jinja2 \ redis \ - dnspython + dnspython \ + psutil COPY data/Dockerfiles/bootstrap /bootstrap diff --git a/data/Dockerfiles/sogo/Dockerfile b/data/Dockerfiles/sogo/Dockerfile index 84255534e..0cdecbc34 100644 --- a/data/Dockerfiles/sogo/Dockerfile +++ b/data/Dockerfiles/sogo/Dockerfile @@ -47,7 +47,8 @@ RUN pip install --break-system-packages \ mysql-connector-python \ jinja2 \ redis \ - dnspython + dnspython \ + psutil COPY data/Dockerfiles/bootstrap /bootstrap