From f6c665fb4eb7fb61fe1bfb6c506a9b9c92af6491 Mon Sep 17 00:00:00 2001 From: Charles Marcoin Date: Tue, 18 Jun 2024 11:49:06 +0200 Subject: [PATCH] added a keycloak service to docker compose --- dev/docker-compose.yml | 16 +++++++++++++++- dev/realm-config.json | 15 +++++++++++++++ 2 files changed, 30 insertions(+), 1 deletion(-) create mode 100644 dev/realm-config.json diff --git a/dev/docker-compose.yml b/dev/docker-compose.yml index 60baad67..6513ec36 100644 --- a/dev/docker-compose.yml +++ b/dev/docker-compose.yml @@ -1,5 +1,19 @@ version: "3.3" services: + keycloak: + image: jboss/keycloak:latest + volumes: + - ./realm-config.json:/tmp/realm-config.json + environment: + - KEYCLOAK_USER=admin + - KEYCLOAK_PASSWORD=keycloakpassword + - DB_VENDOR=h2 + - KEYCLOAK_IMPORT=/tmp/realm-config.json + ports: + - 8080:8080 + command: + - "-b" + - "0.0.0.0" postgres: image: postgres:15 ports: @@ -52,7 +66,7 @@ services: - /etc/localtime:/etc/localtime:ro - wekan-files:/data:rw volumes: - postgresql.conf: + postgresql.conf: testData.sql: createLogsDatabase.sql: wekan-files: diff --git a/dev/realm-config.json b/dev/realm-config.json new file mode 100644 index 00000000..9c45ac22 --- /dev/null +++ b/dev/realm-config.json @@ -0,0 +1,15 @@ +{ + "realm": "master", + "clients": [ + { + "clientId": "signauxfaibles", + "rootUrl": "http://localhost:8081/auth", + "adminUrl": "http://localhost:8081/auth", + "surrogateAuthRequired": true, + "enabled": true, + "redirectUris": [ + "http://localhost:3000/*" + ] + } + ] +}