报错原因
currentServerAddr:http://localhost:8848, err : connect timed out
- SpringCloud连接远程nacos报错,一直提示连接本地的localhost:8848
解决方案
- 在resources目录下创建bootstrap.properties(或bootstrap.yml),再次启动即可
spring.application.name=renren-fast
spring.cloud.nacos.config.server-addr=shopping:8848
spring:
application:
name: renren-fast
cloud:
nacos:
config:
server-addr: shopping:8848