From 4d141b2533ba40b019ccccc4c49677f31ab16a88 Mon Sep 17 00:00:00 2001 From: Alexandre Iooss Date: Thu, 25 Jul 2019 22:10:55 +0200 Subject: [PATCH] [cas] Bump to lastest version --- README.md | 2 ++ django-cas/Dockerfile | 9 ++++++++- django-cas/code/cas/settings.py | 4 +--- .../code/static/{auro.png => cas_server/logo.png} | Bin django-cas/docker-compose.yml | 1 - 5 files changed, 11 insertions(+), 5 deletions(-) rename django-cas/code/static/{auro.png => cas_server/logo.png} (100%) diff --git a/README.md b/README.md index 40e5c7e..7dd44c0 100644 --- a/README.md +++ b/README.md @@ -16,6 +16,7 @@ Les fichiers suivant ne doivent être lisibles que par root : * grafana/ldap.toml * codimd/docker-compose.yml * etherpad/settings.json + * django-cas/docker-compose.yml Mettez dedans les mots de passe de base de données ou du LDAP. @@ -26,4 +27,5 @@ Mettez dedans les mots de passe de base de données ou du LDAP. * 8082 -> Grafana * 8083 -> PrivateBin * 8084 -> EtherPad + * 8085 -> Django CAS server diff --git a/django-cas/Dockerfile b/django-cas/Dockerfile index d1ae237..be9df11 100644 --- a/django-cas/Dockerfile +++ b/django-cas/Dockerfile @@ -7,12 +7,19 @@ FROM debian:buster-slim RUN apt-get update && apt-get install -y \ - python3-django-cas-server \ + python3-pip \ + python3-django \ + python3-lxml \ + python3-requests \ + python3-requests-futures \ + python3-six \ python3-psycopg2 \ python3-whitenoise \ python3-ldap3 \ gunicorn3 +RUN pip3 install django-cas-server + COPY ./code /code/ WORKDIR /code/ EXPOSE 8000 diff --git a/django-cas/code/cas/settings.py b/django-cas/code/cas/settings.py index 5f440f5..6a4e93a 100644 --- a/django-cas/code/cas/settings.py +++ b/django-cas/code/cas/settings.py @@ -135,7 +135,7 @@ STATIC_URL = '/static/' STATICFILES_STORAGE = 'whitenoise.storage.CompressedManifestStaticFilesStorage' STATICFILES_DIRS = [os.path.join(BASE_DIR, "static")] -STATIC_ROOT = os.path.join(BASE_DIR, "static_files/") +STATIC_ROOT = os.path.join(BASE_DIR, "staticfiles") CAS_AUTH_CLASS = "cas_server.auth.LdapAuthUser" CAS_LDAP_SERVER = os.getenv('DJANGO_CAS_LDAP_SERVER') @@ -143,8 +143,6 @@ CAS_LDAP_USER = os.getenv('DJANGO_CAS_LDAP_USER') CAS_LDAP_PASSWORD = os.getenv('DJANGO_CAS_LDAP_PASSWORD') CAS_LDAP_BASE_DN = os.getenv('DJANGO_CAS_LDAP_BASE_DN') -CAS_LOGO_URL = "/static/auro.png" - CAS_INFO_MESSAGES_ORDER = ["cas_explained"] CAS_NEW_VERSION_HTML_WARNING = False diff --git a/django-cas/code/static/auro.png b/django-cas/code/static/cas_server/logo.png similarity index 100% rename from django-cas/code/static/auro.png rename to django-cas/code/static/cas_server/logo.png diff --git a/django-cas/docker-compose.yml b/django-cas/docker-compose.yml index b376d96..db57fa0 100644 --- a/django-cas/docker-compose.yml +++ b/django-cas/docker-compose.yml @@ -23,7 +23,6 @@ services: DJANGO_DB_PASSWORD: caspass DJANGO_SECRET_KEY: "Please change me in production !" DJANGO_HOST: localhost - DJANGO_DEBUG: "false" DJANGO_CAS_LDAP_SERVER: "re2o-ldap.adm.auro.re" DJANGO_CAS_LDAP_USER: "cn=cas,ou=service-users,dc=auro,dc=re" DJANGO_CAS_LDAP_PASSWORD: "Change me in prod !"