This answer is related to Is external infinispan required for Keycloak HA? - #2 by weltonrodrigo, but specific to bitnami:
Taking a look into the bitnami chart, I see that:
- It comes with cache configured out of the box (kubernetes stack, headless service and java_opts_append set with jgroups configuration.
So, 2 replicas of this pod will find each other and form a cluster out of the box, with no intervention necessary.
It’s important to note that CLUSTERED MODE DEPENDS ON A EXTERNAL DATABASE.
So, if you are just running the Keycloak instances, you’ll need to configure them to talk to a single database. Not sure how to do that in the bitnami chart, but should be pretty straightforward.