consul 定制配置检查地址

106 阅读1分钟

定制检查http地址:参数为:health-check-url 定制 ip地址:address

cloud:
  consul:
    host: localhost
    port: 8500
    discovery:
      instance-id: ${spring.application.name}:${vcap.application.instance_id:${spring.application.instance_id:${random.value}}}:${server.port}
      healthCheckInterval: 5s
      serviceName: ${spring.application.name}
      preferIpAddress: true
      health-check-url: http://localhost:8130/actuator/health
      ip-address: localhost