Connection
consul
Main binary to interact with Consul
consul agent -dev
Start a development Consul agent
consul connect
Connect to the Consul agent
consul info
Display information about the local Consul agent
Service Discovery
consul catalog services
List all registered services
consul catalog nodes
List all registered nodes
consul catalog service
List all instances of a service
consul catalog node
List all services registered on a node
Key-Value Store
consul kv put
Put a value in the key-value store
consul kv get
Get a value from the key-value store
consul kv delete
Delete a key-value pair
consul kv export [prefix]
Export KV data
consul kv import
Import KV data
Health Checks
consul members
List members of the Consul cluster
consul monitor
Stream logs from a Consul agent
consul reload
Reload agent configuration
consul health service
Check health of a service
consul health checks
List checks for a service
consul health state
List checks in a state (critical, warning, passing)
ACL
consul acl bootstrap
Bootstrap the ACL system
consul acl token create
Create a new ACL token
consul acl token list
List ACL tokens
consul acl policy create
Create an ACL policy
consul acl role create
Create an ACL role
DNS Interface
dig @127.0.0.1 -p 8600 .service.consul
Query DNS for service address
dig @127.0.0.1 -p 8600 .service.consul SRV
Query DNS for service SRV record
HTTP API
curl http://localhost:8500/v1/catalog/services
List all registered services via HTTP API
curl http://localhost:8500/v1/health/service/
Check health of a service via HTTP API
curl http://localhost:8500/v1/kv/
Get a value from KV store via HTTP API
curl -X PUT -d http://localhost:8500/v1/kv/
Put a value in KV store via HTTP API