Repository navigation
Keycloak Service onn EC2 Instance : You will need local access to create the temporary administrative user. #38720
Replies: 2 comments
|
Thanks for reporting this issue, but as this is reported against an older and unsupported release we are not able to evaluate the issue. Please verify with the nightly build or the latest release. If the issue can be reproduced in the nightly build or latest release add a comment with additional information, otherwise this issue will be automatically closed within 14 days. |
|
Moved to a discussion. KC_BOOTSTRAP environment variables must be set prior to the initial launch of keycloak. Once the master realm exists, they will be ignored. If you have missed the chance to use KC_BOOTSTRAP, you may use the bootstrap admin commands - https://www.keycloak.org/server/bootstrap-admin-recovery These don't need local access, but do need to be configured to access the database the server is using. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Description
Environment Details:
Keycloak Version: Keycloak 26.0.2
Operating System: Amazon Linux 2
Deployment Method: Running as a standalone service on EC2
Java Version: OpenJDK Runtime Environment Corretto-17.0.14.7.1 (build 17.0.14+7-LTS)
Database: Not using any database
Reverse Proxy: None
We are experiencing a problem after setting up keycloak on AWS EC2 Linux Instance with SSL certificate properly instance https://keycloak-dev.adelphis.co:8443/. UI shows the given error but when I hit this URL in browser https://keycloak-dev.adelphis.co:8443/admin, it shows login, password fields but on providing even the valid credentials it does not authenticate the user. I am not able to make it work. Can anybody suggest some solution?
Local access required
You will need local access to create the temporary administrative user.
To create the temporary administrative user open https://localhost:8443/, or set the environment variables KC_BOOTSTRAP_ADMIN_USERNAME and KC_BOOTSTRAP_ADMIN_PASSWORD when starting the server.
I am running it as a service by confguring keycloak service
GNU nano 8.3
[Unit]
Description=Keycloak Service
After=network.target
[Service]
User=keycloak
Group=keycloak
WorkingDirectory=/opt/keycloak
Environment="KC_BOOTSTRAP_ADMIN_USERNAME="
Environment="KC_BOOTSTRAP_ADMIN_PASSWORD="
ExecStart=/opt/keycloak/bin/kc.sh start
--hostname=keycloak-dev.adelphis.co
--http-enabled=true
--http-port=8080
--https-port=8443
--https-certificate-file=/etc/letsencrypt/live/keycloak-dev.adelphis.co/fullchain.pem
--https-certificate-key-file=/etc/letsencrypt/live/keycloak-dev.adelphis.co/privkey.pem
Restart=always
LimitNOFILE=65536
[Install]
WantedBy=multi-user.target
I have already tried setting up the username and password on command CLI
export KC_BOOTSTRAP_ADMIN_USERNAME=''
export KC_BOOTSTRAP_ADMIN_PASSWORD=''
I would appreciate that If somebody can suggest me some solution.
Best,
Bilal
All reactions