-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
28 lines (20 loc) · 849 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
FROM alpine:3.20 as build
RUN apk --update --no-cache add openjdk21 maven
RUN mvn dependency:copy -Dartifact=com.jayway.jsonpath:json-path:2.8.0 -DoutputDirectory=/deps
COPY ./external-claim-mapper/src /src/external-claim-mapper/src
COPY ./external-claim-mapper/pom.xml /src/external-claim-mapper/pom.xml
COPY ./pom.xml /src/pom.xml
RUN mvn clean package -f /src/pom.xml
FROM quay.io/keycloak/keycloak:25.0.0 as debug
COPY --from=build /deps /opt/keycloak/providers
COPY --from=build /src/external-claim-mapper/target/. /opt/keycloak/providers
RUN /opt/keycloak/bin/kc.sh build
ENV KEYCLOAK_ADMIN='admin'
ENV KEYCLOAK_ADMIN_PASSWORD='admin'
ENV DEBUG='true'
ENV DEBUG_SUSPEND='n'
ENV DEBUG_PORT='*:5005'
ENV KC_DB='postgres'
ENV KC_DB_URL='jdbc:postgresql://postgres:5432/keycloak'
ENV KC_DB_USERNAME='keycloak'
ENV KC_DB_PASSWORD='keycloak'