Skip to content

Commit

Permalink
use nightly keycloak and use 2 isntances in docker compose
Browse files Browse the repository at this point in the history
  • Loading branch information
ikethecoder committed Nov 30, 2024
1 parent 3a4d590 commit f8320fe
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
8 changes: 5 additions & 3 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
name: e2e
version: '3.8'

x-common-variables: &common-variables
Expand All @@ -11,17 +12,18 @@ services:
keycloak-nodes:
image: keycloak:latest
deploy:
replicas: 1
replicas: 2
endpoint_mode: dnsrr
build:
context: .
dockerfile: ./local/keycloak/Dockerfile
depends_on:
- kong-db
command: [
command:
[
'start',
'--optimized',
#'--cache=ispn',
'--cache=ispn',
'--hostname',
'http://keycloak.localtest.me:9081/auth',
'--db-url',
Expand Down
4 changes: 2 additions & 2 deletions local/keycloak/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
FROM quay.io/keycloak/keycloak:26.0.6 as builder
FROM quay.io/keycloak/keycloak:nightly as builder

ENV KC_DB=postgres
RUN /opt/keycloak/bin/kc.sh build --http-relative-path=/auth

FROM quay.io/keycloak/keycloak:26.0.6
FROM quay.io/keycloak/keycloak:nightly
COPY --from=builder /opt/keycloak/ /opt/keycloak/
WORKDIR /opt/keycloak
ENTRYPOINT ["/opt/keycloak/bin/kc.sh"]
Expand Down
4 changes: 2 additions & 2 deletions local/keycloak/nginx-lb.conf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
upstream backend {
server api-services-portal-keycloak-nodes-1:9081;
# server api-services-portal-keycloak-nodes-2:9081;
server e2e-keycloak-nodes-1:9081;
server e2e-keycloak-nodes-2:9081;
}

server {
Expand Down

0 comments on commit f8320fe

Please sign in to comment.