@@ -16,7 +16,9 @@ USER root
1616
1717# Adapt issuer URI
1818# Copy to uaa URL
19- RUN yq e '.issuer.uri = "http://localhost:8080"' -i /uaa.yml \
19+ # Add password.write authority to admin client (needed for password management tests)
20+ RUN yq e '.oauth.clients.admin.authorities += ",password.write"' -i /uaa.yml \
21+ && yq e '.issuer.uri = "http://localhost:8080"' -i /uaa.yml \
2022 && yq e '.uaa.url = .issuer.uri' -i /uaa.yml
2123
2224# Runtime image
@@ -25,19 +27,18 @@ FROM tomcat:10-jdk21
2527# Copy config file from yq image
2628COPY --from=yq /uaa.yml /uaa.yml
2729
28- # Remove pre-installed apps
29- RUN rm -rf /usr/local/tomcat/webapps/*
30-
31- # Copy CF users
30+ # Copy CF users config
3231RUN mkdir -p /usr/local/cf_config
3332COPY uaa.yml /usr/local/cf_config/uaa.yml
3433
35-
36- # Install war from build image
37- COPY --from=builder /uaa/uaa/build/libs/cloudfoundry-identity-uaa-*.war /usr/local/tomcat/webapps/ROOT.war
34+ # Install JAR from build image (Spring Boot executable JAR)
35+ COPY --from=builder /uaa/uaa/build/libs/cloudfoundry-identity-uaa-*.war /app/uaa.jar
3836COPY --from=builder /uaa/k8s/templates/log4j2.properties /log4j2.properties
3937
4038ENV JAVA_OPTS="-DLOGIN_CONFIG_URL=file:///uaa.yml -Dlogging.config=/log4j2.properties -DCLOUDFOUNDRY_CONFIG_PATH=/usr/local/cf_config"
41- ENV spring_profiles=default
39+ ENV SPRING_PROFILES_ACTIVE=default
40+
41+ EXPOSE 8080
4242
43- EXPOSE 8080
43+ # Run as Spring Boot application
44+ CMD java $JAVA_OPTS -jar /app/uaa.jar
0 commit comments