-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
keycloak_quarkus fails to start upon installation #108
Comments
---
- name: Playbook for Keycloak X Hosts
hosts: all
vars:
keycloak_quarkus_admin_password: "remembertochangeme"
roles:
- middleware_automation.keycloak.keycloak_quarkus then you can start adding confgiuration on top of it and relaunch. If you need https, before ansible runs with: keycloak_quarkus_https_enabled: True
keycloak_quarkus_key_file: conf/key.pem
keycloak_quarkus_cert_file: conf/cert.pem you'll need to make the key and cert files available in the target host, |
Thanks for the prompt response @guidograzioli . Keycloak server now starts up. http://localhost:8080 - > Administration Console - > http://localhost:8080/admin/master/console/ From the logs I see there's this info: Which is a bit different from the same INFO of a keycloak installed from the zip file: Maybe some vars settings which are missing? |
I made it work by commenting the following entries in the keycloak.conf:
I just did a diff with the keycloak.conf from the zip distribution and I could see the above params are not included. |
You are correct, the following:
is a setting which moves the webapp context from |
I see. Ok, by setting the keycloak_quarkus_http_relative_path to blank it solves the issues about the auth path:
On the other hand, the Ansible playbook will still create a Keycloak config with hostname=localhost that causes the Admin UI to hang.
Overall, it's weird that by setting "hostname=localhost" in conf/keycloak.conf causes the Admin UI to hang. |
Gotcha, I'll need to debug this with the browser inspector |
seeing the same exact issue, unable to solve it so far |
for my setup (no reverse proxy), i was able to solve this by removing the |
I am also failing to access the admin console after a successful playbook run with a simple:
for what I can see, the problem seems related that the current default configuration is trying to redirect to https://localhost instead of the default http://localhost:8080 |
Removing |
The console will always force to promote http to https when in production mode; to have it running on 8080, without a proxy, in addition to the above, you will need to start in dev-mode, as: keycloak_quarkus_start_dev: true
keycloak_quarkus_proxy_mode: none
keycloak_quarkus_frontend_url: 'http://localhost:8080/' |
The test above is an example of the setup |
still can't login to the admin console, is |
I actually don’t think the frontend url is used at all based on the code.On Sep 19, 2023, at 7:17 AM, Giovanni Toraldo ***@***.***> wrote:
keycloak_quarkus_start_dev: true
keycloak_quarkus_proxy_mode: none
keycloak_quarkus_frontend_url: 'http://localhost:8080/'
still can't login to the admin console, is keycloak_quarkus_frontend_url really used? I don't see any other reference than just the variable declaration
https://github.com/search?q=repo%3Aansible-middleware%2Fkeycloak%20keycloak_quarkus_frontend_url&type=code
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you commented.Message ID: ***@***.***>
|
ouch that's right, the variable is a leftover from the migration from keycloak-legacy (supposed to offer a compatibility config point, but not yet worked on). nevertheless, the two params that do the trick are
|
ok I think I got it, I have a working localhost setup with:
|
Thanks for all the hints! I've raised a quick PR for handling |
The two PRs and the clarifications should be enough for closing, thanks everyone in this thread for contributing. |
SUMMARY
I have installed keycloak with Quarkus as follows:
ansible-playbook -i host.ini playbooks/keycloak_quarkus.yml -e keycloak_quarkus_admin_pass=Password1234 --ask-become-pass
When the installation completes, it fails to start the keycloak server:
I've also tried starting the server from /opt/keycloak with the 'keycloak' user but it does not start and no information is logged:
log.txt
ISSUE TYPE
ANSIBLE VERSION
COLLECTION VERSION
STEPS TO REPRODUCE
Using the following host.ini
The text was updated successfully, but these errors were encountered: