Consul Agent Services
Command: consul services
The services
command has subcommands for interacting with Consul services
registered with the local agent. These provide
useful commands such as register
and deregister
for easily registering
services in scripts, dev mode, etc.
To view all services in the catalog, instead of only agent-local services,
see the catalog services
command.
Usage
Usage: consul services <subcommand>
For the exact documentation for your Consul version, run consul services -h
to
view the complete list of subcommands.
For more information, examples, and usage about a subcommand, click on the name of the subcommand in the sidebar.
Basic Examples
To create a simple service:
To create a service from a configuration file:
To deregister a service: