querqy / chorus

Towards an open source stack for e-commerce search
Apache License 2.0
141 stars 33 forks source link

Keycloak fails on Apple M1 silicon, requires update to v 17.x #122

Closed david-fisher closed 2 years ago

david-fisher commented 2 years ago

Kata 000 step:

docker exec solr1 solr zk cp /security.json zk:security.json -z zoo1:2181

Keycloak doesn't load the configuration from zookeeper, due to a missing udp service:

solr1 | 2022-06-24 17:15:29.285 ERROR (zkCallback-12-thread-2) [ ] o.a.s.c.c.ZkStateReader Error running collections node listener => org.apache.solr.common.SolrException: Well-known config could not be read from url http://keycloak:9080/auth/realms/chorus/.well-known/openid-configuration ... keycloak | ("subsystem" => "jgroups"), keycloak | ("channel" => "ee") keycloak | ]) - failure description: {"WFLYCTL0080: Failed services" => {"org .wildfly.clustering.jgroups.channel.ee" => "java.lang.IllegalStateException: jav a.net.SocketException: Protocol not available keycloak | Caused by: java.lang.IllegalStateException: java.net.SocketExc eption: Protocol not available keycloak | Caused by: java.net.SocketException: Protocol not available"}} keycloak | ESC[0mESC[0m01:08:24,414 INFO [org.jboss.as.server] (ServerServic e Thread Pool -- 45) WFLYSRV0010: Deployed "keycloak-server.war" (runtime-name : "keycloak-server.war")

Updating docker-compose.yml to use version 17.0.1-legacy (wildfly support variant, see ): diff --git a/docker-compose.yml b/docker-compose.yml index fd7a096..40c3144 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -239,7 +239,7 @@ services:

resolves the issue.

Image update referenced in https://github.com/keycloak/keycloak/discussions/8846#discussioncomment-2615669 and the surrounding thread.

As the error came from wildfly, I used the wildfly version, but I do not know if that is necessary.

Relates to #91, #93, #110

epugh commented 2 years ago

Great find.... Do you want to submit a PR? Longer term, we need to move to the latest version of Keycloak which removes the underlying wildfly dependency, and apparently starts up MUCH faster....

david-fisher commented 2 years ago

I don't have write perms to this repo, so I could not do a branch and PR. It's one line, should be easy to do, just remove the -legacy from the change I noted.