KeyCloak is "an open source identity and access management solution." Using a local database, or a variety of backends (think OpenLDAP), you can provide Single Sign-On (SSO) using OpenID, OAuth 2.0, and SAML.
I try to configure Keycloak like it’s describe in the tutorial.
I needed to change only the path of the scripts, environment files etc like you can see here:
# Technically, this could be auto-detected, but we prefer to be prescriptive
DB_VENDOR=postgres
DB_DATABASE=keycloak
DB_ADDR=keycloak-db
DB_USER=keycloak
DB_PASSWORD=mypassword
KEYCLOAK_USER=admin
KEYCLOAK_PASSWORD=myadminpassword
# This is required to run keycloak behind traefik
PROXY_ADDRESS_FORWARDING=true
# What's our hostname?
KEYCLOAK_HOSTNAME=keycloak.myhostname.local
# Tell Postgress what user/password to create
POSTGRES_USER=keycloak
POSTGRES_PASSWORD=mypassword
The service is launched without error but the admin user is not created like you can see in this screenshot:
I tried to use the script add-user-keycloak but it changes nothing at all.
For information I create this swarm node on a NAS Synology with Docker 17.05
I don’t know how to debug more (I saw nothing on the logs).
Is it possible to have some help please?
Thank you,
Romain
Edit:
I go inside the container of keycloak and run a bash terminal.
When I echo KEYCLOAK_USER I see nothing (with the command echo $KEYCLOAK_USER)
I also display all the environment variable but no variables from the keycloak.env are presents.
Edit2:
I finaly have an answer: the Synology Docker version is quite old and contains some bugs and the creation/modify and read an environment files or ENV variables is not well supported.