From ae52961361f221c73e47b330f254c49f40cc6673 Mon Sep 17 00:00:00 2001 From: Nicola Tarocco Date: Fri, 9 Jul 2021 16:09:33 +0200 Subject: [PATCH] Fix docker-compose and update README --- README.md | 18 ++++++++++++++++++ app-config/docker-compose.yml | 11 +++++++++++ 2 files changed, 29 insertions(+) diff --git a/README.md b/README.md index 983ba94c..3a036087 100644 --- a/README.md +++ b/README.md @@ -130,6 +130,24 @@ pytest ./cara s2i build file://$(pwd) --copy --keep-symlinks --context-dir ./app-config/nginx/ centos/nginx-112-centos7 cara-nginx-app s2i build file://$(pwd) --copy --keep-symlinks --context-dir ./ centos/python-36-centos7 cara-webservice s2i build file://$(pwd) --copy --keep-symlinks --context-dir ./app-config/auth-service centos/python-36-centos7 auth-service +``` + +Get the client secret from the CERN Application portal for the `cara-test` app. See [CERN-SSO-integration](#CERN-SSO-integration) for more info. +``` +read CLIENT_SECRET +``` + +Define some env vars (copy/paste): +``` +export COOKIE_SECRET=$(openssl rand -hex 50) +export OIDC_SERVER=https://auth.cern.ch/auth +export OIDC_REALM=CERN +export CLIENT_ID=cara-test +export CLIENT_SECRET +``` + +Run docker-compose: +``` cd app-config docker-compose up ``` diff --git a/app-config/docker-compose.yml b/app-config/docker-compose.yml index 145d1253..e322e394 100644 --- a/app-config/docker-compose.yml +++ b/app-config/docker-compose.yml @@ -10,6 +10,15 @@ services: environment: - COOKIE_SECRET - APP_NAME=cara-webservice + - CARA_CALCULATOR_PREFIX=/calculator-cern + - CARA_THEME=cara/apps/calculator/themes/cern + + cara-calculator-open: + image: cara-webservice + environment: + - COOKIE_SECRET + - APP_NAME=cara-webservice + - CARA_CALCULATOR_PREFIX=/calculator-open auth-service: image: auth-service @@ -27,6 +36,8 @@ services: depends_on: cara-webservice: condition: service_started + cara-calculator-open: + condition: service_started cara-app: condition: service_started auth-service: