只要注册时服务名相同就会形成集群
server:
port: 8001
eureka:
client:
serviceUrl:
defaultZone: http://127.0.0.1:7001/eureka/,http://127.0.0.1:7002/eureka/,http://127.0.0.1:7003/eureka/
instance:
prefer-ip-address: true #跨域访问
spring:
application:
name: client-demo #服务名,这里的服务名相同即可