Closed VINO42 closed 4 years ago
Is this a bug? it registed in nacos is a illegal ip, so it was not in the network segment with other services . It should not be my localhost ip, it's weird. There is no java applications running on my localhost machine . I had checked.
changed to jar
Which Component springboot2.3.2+spring-cloud-alibaba2.2.3.RELEASE+SpringCloud-Hoxton-SR8
Describe the bug I deployed an old project with war rebuilded with springboot2.3.2 deployed in war, ,this service registed in nacos , but the registed ip is not correct, it is my localhost eth0 ipv4, this is curious, port is correct.
To Reproduce Steps to reproduce the behavior:
Expected behavior registed in nacos with the tomcat port and the ip should be the machine eth0 ip; such as :172.xx.xx.xx Screenshots below is nacos registed service instance :
and below is my localhost ipconfigs:
Additional context use jdk8, build springboot with war nacos regist codes: ` @Slf4j @Component public class NacosListener implements ApplicationListener {
} ` AND THE REGISTED LOG:
configs in bootstrap.properties:
when project started , request the nacos endpoint /actuator/nacos-discovery,get the correct configs:
use annotations :