consul-api
consul-api copied to clipboard
does token supports now ?
i have a consul cluster with acl enabled.
[root@a-docker-cluster04 ~]# consul members -token=a59c2700-49fc-0786-9932-b0ffec5fc3c9
Node Address Status Type Build Protocol DC Segment
a-docker-cluster01 172.18.8.200:8301 alive server 1.4.2 2 sz <all>
a-docker-cluster02 172.18.8.201:8301 alive server 1.4.2 2 sz <all>
a-docker-cluster03 172.18.8.202:8301 alive server 1.4.2 2 sz <all>
a-docker-cluster04 172.18.8.196:8301 alive server 1.4.2 2 sz <all>
a-docker-cluster05 172.18.8.197:8301 alive server 1.4.2 2 sz <all>
but what i got is 'Caused by: com.ecwid.consul.v1.OperationException: OperationException(statusCode=403, statusMessage='Forbidden', statusContent='ACL not found')' when using spring cloud.
version

config here is my config.
logging:
level:
org.springframework.cloud.consul: DEBUG
file: logs/access.log
spring:
application:
name: gateway
cloud:
consul:
enabled: true
host: svc-center-v1.xxx.cc
port: 80
config:
watch:
enabled: false
enabled: true
name: gateway
prefix: config
defaultContext: share
profileSeparator: '-'
format: yaml
data-key: data-key
acl-token: a59c2700-49fc-0786-9932-b0ffec5fc3c9
discovery:
prefer-ip-address: true
tags: env=${spring.profiles.active}
default-query-tag: env=${spring.profiles.active}
health-check-critical-timeout: 60s
health-check-interval: 10s
health-check-timeout: 5s
acl-token: a59c2700-49fc-0786-9932-b0ffec5fc3c9