Eureka出现Connect to localhost:8761 timed out问题

原先使用application.properties


spring.application.name=hello-service
eureka.client.service-url.defauleZone=http://127.0.0.1:1111/eureka/
eureka.instance.prefer-ip-address=true
eureka.instance.ip-address=127.0.0.1

修改为:application.yml

eureka:
client:
service-url:
defaultZone: http://127.0.0.1:1111/eureka/

instance:
prefer-ip-address: true
ip-address: 127.0.0.1
spring:
application:
name: helloService
 
posted @ 2022-06-16 17:35  成年人35以上痛的开发  阅读(213)  评论(0编辑  收藏  举报