Skip to content

Commit 0ed9ead

Browse files
committed
Eureka configurations updated
1 parent 1582ada commit 0ed9ead

File tree

3 files changed

+12
-6
lines changed

3 files changed

+12
-6
lines changed

eureka/eureka-client/src/main/resources/application.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,11 @@ server:
88
contextPath: /test
99

1010
eureka:
11+
server:
12+
host: localhost:8761
13+
contextPath: serviceregistry
1114
client:
1215
serviceUrl:
13-
defaultZone: ${EUREKA_URI:http://localhost:8761/eureka}
16+
defaultZone: ${EUREKA_URI:http://${eureka.server.host}/${eureka.server.contextPath}/eureka}
1417
instance:
1518
preferIpAddress: true

eureka/eureka-feign-client/src/main/resources/application.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,11 @@ server:
1111
port: 8080
1212

1313
eureka:
14+
server:
15+
host: localhost:8761
16+
contextPath: serviceregistry
1417
client:
1518
serviceUrl:
16-
defaultZone: ${EUREKA_URI:http://localhost:8761/eureka}
19+
defaultZone: ${EUREKA_URI:http://${eureka.server.host}/${eureka.server.contextPath}/eureka}
20+
instance:
21+
preferIpAddress: true

eureka/eureka-server/src/main/resources/application.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,18 @@
11
server:
22
port: 8761
3-
4-
server:
53
servlet:
64
contextPath: /serviceregistry
75

86
# Standalone configuration
97
eureka:
108
instance:
11-
hostname: registry
9+
hostname: localhost
1210
client:
1311
register-with-eureka: false
1412
fetch-registry: false
1513
serviceUrl:
1614
# default zone points to self
17-
defaultZone: http://${eureka.instance.hostname}:${server.port}/eureka/
15+
defaultZone: http://${eureka.instance.hostname}:${server.port}/${server.contextPath}/eureka/
1816

1917

2018
logging:

0 commit comments

Comments
 (0)