From 3279450f552fe21b9b64dee7a89044e1b15cb698 Mon Sep 17 00:00:00 2001 From: thespad Date: Sun, 14 Jul 2024 18:54:36 +0100 Subject: [PATCH] Add necessary packages for ldap support --- Dockerfile | 4 +++- Dockerfile.aarch64 | 4 +++- root/etc/s6-overlay/s6-rc.d/init-netbox-config/run | 3 +++ 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index a5443f4..64acc18 100644 --- a/Dockerfile +++ b/Dockerfile @@ -18,15 +18,16 @@ RUN \ libffi-dev \ libxslt-dev \ libxml2-dev \ + openldap-dev \ openssl-dev \ postgresql-dev \ python3-dev \ zlib-dev && \ echo "**** install runtime packages ****" && \ apk add --no-cache --upgrade \ - tiff \ postgresql-client \ python3 \ + tiff \ uwsgi \ uwsgi-python && \ echo "**** install netbox ****" && \ @@ -48,6 +49,7 @@ RUN \ pip \ wheel && \ pip install --no-cache-dir --find-links https://wheel-index.linuxserver.io/alpine-3.20/ -r requirements.txt && \ + pip install --no-cache-dir django-auth-ldap && \ printf "Linuxserver.io version: ${VERSION}\nBuild-date: ${BUILD_DATE}" > /build_version && \ echo "**** cleanup ****" && \ apk del --purge \ diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64 index d199553..4612ff9 100644 --- a/Dockerfile.aarch64 +++ b/Dockerfile.aarch64 @@ -18,15 +18,16 @@ RUN \ libffi-dev \ libxslt-dev \ libxml2-dev \ + openldap-dev \ openssl-dev \ postgresql-dev \ python3-dev \ zlib-dev && \ echo "**** install runtime packages ****" && \ apk add --no-cache --upgrade \ - tiff \ postgresql-client \ python3 \ + tiff \ uwsgi \ uwsgi-python && \ echo "**** install netbox ****" && \ @@ -48,6 +49,7 @@ RUN \ pip \ wheel && \ pip install --no-cache-dir --find-links https://wheel-index.linuxserver.io/alpine-3.20/ -r requirements.txt && \ + pip install --no-cache-dir django-auth-ldap && \ printf "Linuxserver.io version: ${VERSION}\nBuild-date: ${BUILD_DATE}" > /build_version && \ echo "**** cleanup ****" && \ apk del --purge \ diff --git a/root/etc/s6-overlay/s6-rc.d/init-netbox-config/run b/root/etc/s6-overlay/s6-rc.d/init-netbox-config/run index bf19072..152530a 100755 --- a/root/etc/s6-overlay/s6-rc.d/init-netbox-config/run +++ b/root/etc/s6-overlay/s6-rc.d/init-netbox-config/run @@ -47,6 +47,9 @@ ln -sf /config/media /app/netbox/netbox/media ln -sf /config/configuration.py /app/netbox/netbox/netbox/configuration.py +touch /config/ldap_config.py +ln -sf /config/ldap_config.py /app/netbox/netbox/netbox/ldap_config.py + mv /defaults/uwsgi.ini /app/netbox/netbox/uwsgi.ini > /dev/null 2>&1 # build docs