Command: setup consul
This command sets up Consul for allowing Nomad workloads to authenticate themselves using Workload Identity.
This command requires acl:write
permissions for Consul and respects
CONSUL_HTTP_TOKEN
, CONSUL_HTTP_ADDR
, and other Consul-related environment
variables.
Warning
This command is an experimental feature and may change its behavior in future versions of Nomad.
Usage
Setup Consul Options
-jwks-url
: URL of Nomad's JWKS endpoint contacted by Consul to verify JWT signatures. Defaults tohttp://localhost:4646/.well-known/jwks.json
.-jwks-ca-file
: Path to a CA certificate file that will be used to validate the JWKS URL if it uses TLS.-destroy
: Removes all configuration components this command created from the Consul cluster.-y
: Automatically answersyes
to all the questions, making the setup non-interactive. Defaults tofalse
.
Examples
Below is an example of an interactive session with default options, interrupted
by answering no
to one of the questions, demonstrating the capabilities of the
-destroy
flag.