@@ -17,16 +17,17 @@ class TestcontainersConfiguration {
1717
1818 @ Bean
1919 GenericContainer <?> authorizationServer () {
20- return new GenericContainer <>("bellsoft/liberica-openjre-alpine:21" )
21- .withCopyFileToContainer (MountableFile .forClasspathResource ("authorization-0.0.1-SNAPSHOT.jar" ),
22- "/authorization.jar" )
23- .
withCommand (
"java" ,
"-jar" ,
"/authorization.jar" ,
"[email protected] " ,
24- "--spring.security.user.password=test" ,
25- "--spring.security.oauth2.authorizationserver.client.todo-frontend.registration.client-id=todo-frontend" ,
26- "--spring.security.oauth2.authorizationserver.client.todo-frontend.registration.client-secret={noop}secret" ,
27- "--spring.security.oauth2.authorizationserver.client.todo-frontend.registration.redirect-uris=http://localhost:52241/login/oauth2/code/todo-frontend" ,
28- "--management.zipkin.tracing.export.enabled=false" , "--spring.main.banner-mode=off" ,
29- "--logging.level.org.springframework.security=info" )
20+ return new GenericContainer <>("ghcr.io/making/oauth2-sso-demo/authorization:jvm" )
21+ .
withEnv (
"spring.security.user.name" ,
"[email protected] " )
22+ .withEnv ("spring.security.user.password" , "test" )
23+ .withEnv ("spring.security.oauth2.authorizationserver.client.todo-frontend.registration.client-id" ,
24+ "todo-frontend" )
25+ .withEnv ("spring.security.oauth2.authorizationserver.client.todo-frontend.registration.client-secret" ,
26+ "{noop}secret" )
27+ .withEnv ("spring.security.oauth2.authorizationserver.client.todo-frontend.registration.redirect-uris" ,
28+ "http://localhost:52241/login/oauth2/code/todo-frontend" )
29+ .withEnv ("management.zipkin.tracing.export.enabled" , "false" )
30+ .withEnv ("spring.main.banner-mode" , "off" )
3031 .withExposedPorts (9000 )
3132 .waitingFor (Wait .forHttp ("/actuator/health" ).forPort (9000 ).withStartupTimeout (Duration .ofSeconds (10 )))
3233 .withLogConsumer (new Slf4jLogConsumer (LoggerFactory .getLogger ("authorization-server" )));
0 commit comments