I have created a secret to pass in my admin username and password. However when trying to log into the admin console I get an invalid username/password error. During installation it appears to populate the values from my secret:
spec:
containers:
- name: keycloak
image: quay.io/keycloak/keycloak:12.0.2
env:
- name: KEYCLOAK_USER
valueFrom:
secretKeyRef:
name: keycloak-auth
key: username
- name: KEYCLOAK_PASSWORD
valueFrom:
secretKeyRef:
name: keycloak-auth
key: password
e[0me[0m13:22:34,299 INFO [org.keycloak.services] (ServerService Thread Pool – 65) KC-SERVICES0006: Importing users from ‘/opt/jboss/keycloak/standalone/configuration/keycloak-add-user.json’
e[0me[0m13:22:34,799 INFO [org.keycloak.services] (ServerService Thread Pool – 65) KC-SERVICES0009: Added user 'admin
However when logging in I see the following in the logs:
e[0me[33m13:24:22,528 WARN [org.keycloak.events] (default task-16) type=LOGIN_ERROR, realmId=master, clientId=security-admin-console, userId=null, ipAddress=172.16.220.64, error=user_not_found, auth_method=openid-connect, auth_type=code, redirect_uri=, code_id=5a8b2f55-0fe6-4e95-a6d0-6d0c4fe6c1b7, username=admin