Browse Source

Replaced auth-server with localhost

pull/641/head
Steve Riesenberg 4 years ago
parent
commit
c3402b0b12
No known key found for this signature in database
GPG Key ID: 5F311AB48A55D521
  1. 1
      samples/README.adoc
  2. 4
      samples/custom-consent-authorizationserver/src/main/java/sample/config/AuthorizationServerConfig.java
  3. 4
      samples/default-authorizationserver/src/main/java/sample/config/AuthorizationServerConfig.java
  4. 2
      samples/messages-client/src/main/resources/application.yml
  5. 2
      samples/messages-resource/src/main/resources/application.yml

1
samples/README.adoc

@ -7,7 +7,6 @@ The username is `user1` and the password is `password`.
== Run the Sample == Run the Sample
* Run Authorization Server -> `./gradlew -b samples/default-authorizationserver/samples-default-authorizationserver.gradle bootRun` * Run Authorization Server -> `./gradlew -b samples/default-authorizationserver/samples-default-authorizationserver.gradle bootRun`
** *IMPORTANT:* Make sure to modify your `/etc/hosts` file to avoid problems with session cookie overwrites between `messages-client` and `default-authorizationserver`. Simply add the entry `127.0.0.1 auth-server`
* Run Resource Server -> `./gradlew -b samples/messages-resource/samples-messages-resource.gradle bootRun` * Run Resource Server -> `./gradlew -b samples/messages-resource/samples-messages-resource.gradle bootRun`
* Run Client -> `./gradlew -b samples/messages-client/samples-messages-client.gradle bootRun` * Run Client -> `./gradlew -b samples/messages-client/samples-messages-client.gradle bootRun`
* Go to `http://127.0.0.1:8080` * Go to `http://127.0.0.1:8080`

4
samples/custom-consent-authorizationserver/src/main/java/sample/config/AuthorizationServerConfig.java

@ -1,5 +1,5 @@
/* /*
* Copyright 2020-2021 the original author or authors. * Copyright 2020-2022 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -103,7 +103,7 @@ public class AuthorizationServerConfig {
@Bean @Bean
public ProviderSettings providerSettings() { public ProviderSettings providerSettings() {
return ProviderSettings.builder().issuer("http://auth-server:9000").build(); return ProviderSettings.builder().issuer("http://localhost:9000").build();
} }
@Bean @Bean

4
samples/default-authorizationserver/src/main/java/sample/config/AuthorizationServerConfig.java

@ -1,5 +1,5 @@
/* /*
* Copyright 2020-2021 the original author or authors. * Copyright 2020-2022 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -107,7 +107,7 @@ public class AuthorizationServerConfig {
@Bean @Bean
public ProviderSettings providerSettings() { public ProviderSettings providerSettings() {
return ProviderSettings.builder().issuer("http://auth-server:9000").build(); return ProviderSettings.builder().issuer("http://localhost:9000").build();
} }
@Bean @Bean

2
samples/messages-client/src/main/resources/application.yml

@ -41,7 +41,7 @@ spring:
client-name: messaging-client-client-credentials client-name: messaging-client-client-credentials
provider: provider:
spring: spring:
issuer-uri: http://auth-server:9000 issuer-uri: http://localhost:9000
messages: messages:
base-uri: http://127.0.0.1:8090/messages base-uri: http://127.0.0.1:8090/messages

2
samples/messages-resource/src/main/resources/application.yml

@ -14,4 +14,4 @@ spring:
oauth2: oauth2:
resourceserver: resourceserver:
jwt: jwt:
issuer-uri: http://auth-server:9000 issuer-uri: http://localhost:9000

Loading…
Cancel
Save