当前位置: 首页 > 工具软件 > ip-laslant > 使用案例 >

Spring Cloud yml配置文件中 eureka. instance. prefer-ip-address: true

杨曜瑞
2023-12-01

eureka:
client:
service-url:
defaultZone: http://long.abc.com:8761/eureka/ 使用域名访问,这使会需要设置host,设置域名 对应 的IP
instance:
prefer-ip-address: true

instance:
prefer-ip-address: true 的作用是注册服务的时候使用ip地址,ip地址从host里面找。

 类似资料: