From f5dabb18d695318627ee97c900b6f34c4e0fdf74 Mon Sep 17 00:00:00 2001 From: Nicola Stoira <nicola.stoira@accenture.com> Date: Tue, 21 May 2024 11:57:01 +0200 Subject: [PATCH 1/7] Define machine CPUs with logical=True --- lib/config.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/config.py b/lib/config.py index b10eeb68..e371b497 100644 --- a/lib/config.py +++ b/lib/config.py @@ -71,7 +71,7 @@ class Config(object): if config_data.get('machine', {}).get('cpus') is not None: self.machine_cpus = int(config_data.get('machine', {}).get('cpus')) else: - self.machine_cpus = psutil.cpu_count(logical=False) + self.machine_cpus = psutil.cpu_count(logical=True) # Parallelization option for the Connector self.parallel_projects = int(config_data.get('parallelization', {}).get('parallel_projects', 3)) -- GitLab From 370ffd5fdd12488e5fbe40e1ee7623382cc2d3bd Mon Sep 17 00:00:00 2001 From: Nicola Stoira <nicola.stoira@accenture.com> Date: Tue, 21 May 2024 13:10:48 +0200 Subject: [PATCH 2/7] Update package --- postgres/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/postgres/Dockerfile b/postgres/Dockerfile index 4c106a51..fd928c9b 100644 --- a/postgres/Dockerfile +++ b/postgres/Dockerfile @@ -66,7 +66,7 @@ RUN set -eux; \ krb5-dev \ libc-dev \ libedit-dev \ - libxml2-dev=2.11.7-r0 \ + libxml2-dev \ libxslt-dev \ linux-headers \ make \ -- GitLab From c23b1f5c5e2e2e65d5848cb5f7fca0605e6da016 Mon Sep 17 00:00:00 2001 From: Nicola Stoira <nicola.stoira@accenture.com> Date: Tue, 21 May 2024 13:14:00 +0200 Subject: [PATCH 3/7] Remove versions --- conf/Dockerfile | 2 +- grafana/Dockerfile | 2 +- pgadmin/Dockerfile | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/conf/Dockerfile b/conf/Dockerfile index 9ba270f7..d492f792 100644 --- a/conf/Dockerfile +++ b/conf/Dockerfile @@ -14,7 +14,7 @@ FROM registry.dcc.sib.swiss/sphn-semantic-framework/sphn-connector/nginx:unprivi USER root RUN addgroup sphn_proxy && adduser -u 1000 -D sphn_proxy -G sphn_proxy -RUN apk update && apk add --no-cache curl==8.5.0-r0 libcrypto3==3.1.4-r6 libcurl==8.5.0-r0 curl=8.5.0-r0 libssl3=3.1.4-r6 libexpat=2.6.2-r0 libxml2=2.11.7-r0 +RUN apk update && apk add --no-cache curl==8.5.0-r0 libcrypto3==3.1.4-r6 libcurl==8.5.0-r0 curl=8.5.0-r0 libssl3 libexpat=2.6.2-r0 libxml2 # Set the working directory WORKDIR /usr/share/nginx/html diff --git a/grafana/Dockerfile b/grafana/Dockerfile index d0aa41fa..1836e473 100644 --- a/grafana/Dockerfile +++ b/grafana/Dockerfile @@ -21,7 +21,7 @@ ENV DASHBOARDS_TARGET=/etc/grafana/provisioning/dashboards USER root #Update APK libraries -RUN apk update && apk add --no-cache curl==8.5.0-r0 libcrypto3==3.1.4-r6 libcurl==8.5.0-r0 libssl3==3.1.4-r6 nghttp2-libs==1.58.0-r0 +RUN apk update && apk add --no-cache curl==8.5.0-r0 libcrypto3==3.1.4-r6 libcurl==8.5.0-r0 libssl3 nghttp2-libs==1.58.0-r0 USER grafana # setting up dashboard & dataresources config diff --git a/pgadmin/Dockerfile b/pgadmin/Dockerfile index 1d327f62..98fb5c92 100644 --- a/pgadmin/Dockerfile +++ b/pgadmin/Dockerfile @@ -18,7 +18,7 @@ RUN groupadd -r sphn_pgadmin && useradd --no-log-init -r -g sphn_pgadmin sphn_pg RUN /venv/bin/python3 -m pip install --upgrade pip \ && /venv/bin/python3 -m pip install Werkzeug==2.3.8 cryptography==42.0.4 sqlparse==0.5.0 gunicorn==22.0.0\ -&& apk update && apk add --no-cache --upgrade libcrypto3=3.1.4-r6 libssl3=3.1.4-r6 sqlite-libs==3.41.2-r3 libexpat=2.6.2-r0 +&& apk update && apk add --no-cache --upgrade libcrypto3=3.1.4-r6 libssl3 sqlite-libs==3.41.2-r3 libexpat=2.6.2-r0 RUN chown -R sphn_pgadmin:sphn_pgadmin /var/lib/pgadmin /var/log/ /pgadmin4 RUN chmod -R 755 /var/lib/pgadmin /var/log/ -- GitLab From 5bcb5f3b96ab788acd82caacc04bfe502cba443d Mon Sep 17 00:00:00 2001 From: Nicola Stoira <nicola.stoira@accenture.com> Date: Tue, 21 May 2024 13:18:25 +0200 Subject: [PATCH 4/7] Remove versions --- conf/Dockerfile | 2 +- grafana/Dockerfile | 2 +- pgadmin/Dockerfile | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/conf/Dockerfile b/conf/Dockerfile index d492f792..0976de82 100644 --- a/conf/Dockerfile +++ b/conf/Dockerfile @@ -14,7 +14,7 @@ FROM registry.dcc.sib.swiss/sphn-semantic-framework/sphn-connector/nginx:unprivi USER root RUN addgroup sphn_proxy && adduser -u 1000 -D sphn_proxy -G sphn_proxy -RUN apk update && apk add --no-cache curl==8.5.0-r0 libcrypto3==3.1.4-r6 libcurl==8.5.0-r0 curl=8.5.0-r0 libssl3 libexpat=2.6.2-r0 libxml2 +RUN apk update && apk add --no-cache curl==8.5.0-r0 libcrypto3 libcurl==8.5.0-r0 curl=8.5.0-r0 libssl3 libexpat=2.6.2-r0 libxml2 # Set the working directory WORKDIR /usr/share/nginx/html diff --git a/grafana/Dockerfile b/grafana/Dockerfile index 1836e473..4831ca28 100644 --- a/grafana/Dockerfile +++ b/grafana/Dockerfile @@ -21,7 +21,7 @@ ENV DASHBOARDS_TARGET=/etc/grafana/provisioning/dashboards USER root #Update APK libraries -RUN apk update && apk add --no-cache curl==8.5.0-r0 libcrypto3==3.1.4-r6 libcurl==8.5.0-r0 libssl3 nghttp2-libs==1.58.0-r0 +RUN apk update && apk add --no-cache curl==8.5.0-r0 libcrypto3 libcurl==8.5.0-r0 libssl3 nghttp2-libs==1.58.0-r0 USER grafana # setting up dashboard & dataresources config diff --git a/pgadmin/Dockerfile b/pgadmin/Dockerfile index 98fb5c92..7bc02463 100644 --- a/pgadmin/Dockerfile +++ b/pgadmin/Dockerfile @@ -18,7 +18,7 @@ RUN groupadd -r sphn_pgadmin && useradd --no-log-init -r -g sphn_pgadmin sphn_pg RUN /venv/bin/python3 -m pip install --upgrade pip \ && /venv/bin/python3 -m pip install Werkzeug==2.3.8 cryptography==42.0.4 sqlparse==0.5.0 gunicorn==22.0.0\ -&& apk update && apk add --no-cache --upgrade libcrypto3=3.1.4-r6 libssl3 sqlite-libs==3.41.2-r3 libexpat=2.6.2-r0 +&& apk update && apk add --no-cache --upgrade libcrypto3 libssl3 sqlite-libs==3.41.2-r3 libexpat=2.6.2-r0 RUN chown -R sphn_pgadmin:sphn_pgadmin /var/lib/pgadmin /var/log/ /pgadmin4 RUN chmod -R 755 /var/lib/pgadmin /var/log/ -- GitLab From 51579a5e550da73e1fcb77eb50c8fde56f2e0142 Mon Sep 17 00:00:00 2001 From: Nicola Stoira <nicola.stoira@accenture.com> Date: Tue, 21 May 2024 13:49:41 +0200 Subject: [PATCH 5/7] Update version --- conf/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conf/Dockerfile b/conf/Dockerfile index 0976de82..1d886f53 100644 --- a/conf/Dockerfile +++ b/conf/Dockerfile @@ -14,7 +14,7 @@ FROM registry.dcc.sib.swiss/sphn-semantic-framework/sphn-connector/nginx:unprivi USER root RUN addgroup sphn_proxy && adduser -u 1000 -D sphn_proxy -G sphn_proxy -RUN apk update && apk add --no-cache curl==8.5.0-r0 libcrypto3 libcurl==8.5.0-r0 curl=8.5.0-r0 libssl3 libexpat=2.6.2-r0 libxml2 +RUN apk update && apk add --no-cache curl==8.5.0-r0 libcrypto3 libcurl==8.5.0-r0 curl=8.5.0-r0 libssl3 libexpat=2.6.2-r0 libxml2=2.11.7-r0 # Set the working directory WORKDIR /usr/share/nginx/html -- GitLab From 6ebd96d14c9f340a71d27f93ae13886dcccfe490 Mon Sep 17 00:00:00 2001 From: Nicola Stoira <nicola.stoira@accenture.com> Date: Tue, 21 May 2024 14:13:40 +0200 Subject: [PATCH 6/7] Revert --- conf/Dockerfile | 2 +- connector/app/requirements.txt | 2 +- pgadmin/Dockerfile | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/conf/Dockerfile b/conf/Dockerfile index 1d886f53..0976de82 100644 --- a/conf/Dockerfile +++ b/conf/Dockerfile @@ -14,7 +14,7 @@ FROM registry.dcc.sib.swiss/sphn-semantic-framework/sphn-connector/nginx:unprivi USER root RUN addgroup sphn_proxy && adduser -u 1000 -D sphn_proxy -G sphn_proxy -RUN apk update && apk add --no-cache curl==8.5.0-r0 libcrypto3 libcurl==8.5.0-r0 curl=8.5.0-r0 libssl3 libexpat=2.6.2-r0 libxml2=2.11.7-r0 +RUN apk update && apk add --no-cache curl==8.5.0-r0 libcrypto3 libcurl==8.5.0-r0 curl=8.5.0-r0 libssl3 libexpat=2.6.2-r0 libxml2 # Set the working directory WORKDIR /usr/share/nginx/html diff --git a/connector/app/requirements.txt b/connector/app/requirements.txt index 53c41b41..7e08d562 100644 --- a/connector/app/requirements.txt +++ b/connector/app/requirements.txt @@ -6,7 +6,7 @@ rfc3987==1.3.8 lightrdf==0.3.1 openpyxl==3.1.2 rdflib==6.1.1 -aiohttp==3.9.2 +aiohttp==3.9.4 Werkzeug==2.3.8 cryptography==42.0.4 pyoxigraph==0.3.20 diff --git a/pgadmin/Dockerfile b/pgadmin/Dockerfile index 7bc02463..963ac505 100644 --- a/pgadmin/Dockerfile +++ b/pgadmin/Dockerfile @@ -17,7 +17,7 @@ USER root RUN groupadd -r sphn_pgadmin && useradd --no-log-init -r -g sphn_pgadmin sphn_pgadmin RUN /venv/bin/python3 -m pip install --upgrade pip \ -&& /venv/bin/python3 -m pip install Werkzeug==2.3.8 cryptography==42.0.4 sqlparse==0.5.0 gunicorn==22.0.0\ +&& /venv/bin/python3 -m pip install Werkzeug==3.0.3 cryptography==42.0.4 sqlparse==0.5.0 gunicorn==22.0.0\ && apk update && apk add --no-cache --upgrade libcrypto3 libssl3 sqlite-libs==3.41.2-r3 libexpat=2.6.2-r0 RUN chown -R sphn_pgadmin:sphn_pgadmin /var/lib/pgadmin /var/log/ /pgadmin4 -- GitLab From 7caa45ee0460ee6803451ac5747e87a3e1bb59b5 Mon Sep 17 00:00:00 2001 From: Nicola Stoira <nicola.stoira@accenture.com> Date: Tue, 21 May 2024 17:23:21 +0200 Subject: [PATCH 7/7] Update NGINX base image --- conf/Dockerfile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/conf/Dockerfile b/conf/Dockerfile index 0976de82..9f5ffb9d 100644 --- a/conf/Dockerfile +++ b/conf/Dockerfile @@ -10,7 +10,9 @@ # You should have received a copy of the GNU General Public License # along with this program; if not, see <http://www.gnu.org/licenses/>. # -FROM registry.dcc.sib.swiss/sphn-semantic-framework/sphn-connector/nginx:unprivileged +FROM registry.dcc.sib.swiss/sphn-semantic-framework/sphn-connector/nginx:1.25-alpine-unprivileged + + USER root RUN addgroup sphn_proxy && adduser -u 1000 -D sphn_proxy -G sphn_proxy -- GitLab