diff --git a/config-data/bike-service.yml b/config-data/bike-service.yml index 5bed6d8..1c2703b 100644 --- a/config-data/bike-service.yml +++ b/config-data/bike-service.yml @@ -1,10 +1,10 @@ server: - port: 8003 + port: ${PORT:${SERVER_PORT:0}} eureka: client: fetch-registry: true register-with-eureka: true service-url: default-zone: http://localhost:8761/eureka - instance: - hostname: localhost \ No newline at end of file + instance: + instance-in: ${spring.application.name}:${spring.application.instance_id:${random.value}} \ No newline at end of file diff --git a/config-data/car-service.yml b/config-data/car-service.yml index 1191ca9..1c2703b 100644 --- a/config-data/car-service.yml +++ b/config-data/car-service.yml @@ -1,10 +1,10 @@ server: - port: 8002 + port: ${PORT:${SERVER_PORT:0}} eureka: client: fetch-registry: true register-with-eureka: true service-url: default-zone: http://localhost:8761/eureka - instance: - hostname: localhost \ No newline at end of file + instance: + instance-in: ${spring.application.name}:${spring.application.instance_id:${random.value}} \ No newline at end of file diff --git a/config-data/eureka-service.yml b/config-data/eureka-service.yml index edb74fe..6cc3c34 100644 --- a/config-data/eureka-service.yml +++ b/config-data/eureka-service.yml @@ -3,4 +3,6 @@ server: eureka: client: fetch-registry: false - register-with-eureka: false \ No newline at end of file + register-with-eureka: false + service-url: + default-zone: http://${eureka.instance.hostname}:${server.port}/eureka/ \ No newline at end of file diff --git a/config-data/user-service.yml b/config-data/user-service.yml index 43267d7..1c2703b 100644 --- a/config-data/user-service.yml +++ b/config-data/user-service.yml @@ -1,10 +1,10 @@ server: - port: 8001 + port: ${PORT:${SERVER_PORT:0}} eureka: client: fetch-registry: true register-with-eureka: true service-url: default-zone: http://localhost:8761/eureka - instance: - hostname: localhost \ No newline at end of file + instance: + instance-in: ${spring.application.name}:${spring.application.instance_id:${random.value}} \ No newline at end of file