mirror of https://github.com/status-im/consul.git
docs: simplify agent docs slugs
This commit is contained in:
parent
448f50c459
commit
24c67f2dfa
|
@ -35,7 +35,7 @@ Every Consul Enterprise server maintains a reconciliation routine where every 30
|
|||
|
||||
Joining a network area pool involves:
|
||||
1. Setting memberlist and Serf configuration.
|
||||
* Prior to Consul `v1.8.11` and `v1.9.5`, network areas were configured with memberlist's [DefaultWANConfig](https://github.com/hashicorp/memberlist/blob/838073fef1a4e1f6cb702a57a8075304098b1c31/config.go#L315). This was then updated to instead use the server's [gossip_wan](https://www.consul.io/docs/agent/config/agent-config-files#gossip_wan) configuration, which falls back to the DefaultWANConfig if it was not specified.
|
||||
* Prior to Consul `v1.8.11` and `v1.9.5`, network areas were configured with memberlist's [DefaultWANConfig](https://github.com/hashicorp/memberlist/blob/838073fef1a4e1f6cb702a57a8075304098b1c31/config.go#L315). This was then updated to instead use the server's [gossip_wan](https://www.consul.io/docs/agent/config/config-files#gossip_wan) configuration, which falls back to the DefaultWANConfig if it was not specified.
|
||||
* As of Consul `v1.8.11`/`v1.9.5` it is not possible to tune gossip communication on a per-area basis.
|
||||
|
||||
2. Update the server's gossip network, which keeps track of network areas that the server is a part of. This gossip network is also used to dispatch incoming **gossip** connections to handlers for the appropriate area.
|
||||
|
|
|
@ -13,7 +13,7 @@ See also the [checklist for adding a new field] to the configuration.
|
|||
[Agent Configuration]: https://www.consul.io/docs/agent/config
|
||||
[checklist for adding a new field]: ./checklist-adding-config-fields.md
|
||||
[Auto-Config]: #auto-config
|
||||
[Config Entries]: https://www.consul.io/docs/agent/config/agent-config-files#config_entries
|
||||
[Config Entries]: https://www.consul.io/docs/agent/config/config-files#config_entries
|
||||
[Services]: https://www.consul.io/docs/discovery/services
|
||||
[Checks]: https://www.consul.io/docs/discovery/checks
|
||||
|
||||
|
@ -53,6 +53,6 @@ implemented in a couple packages.
|
|||
* the server RPC endpoint is in [agent/consul/auto_config_endpoint.go]
|
||||
* the client that receives and applies the config is implemented in [agent/auto-config]
|
||||
|
||||
[auto_config]: https://www.consul.io/docs/agent/config/agent-config-files#auto_config
|
||||
[auto_config]: https://www.consul.io/docs/agent/config/config-files#auto_config
|
||||
[agent/consul/auto_config_endpoint.go]: https://github.com/hashicorp/consul/blob/main/agent/consul/auto_config_endpoint.go
|
||||
[agent/auto-config]: https://github.com/hashicorp/consul/tree/main/agent/auto-config
|
||||
|
|
|
@ -55,7 +55,7 @@ There are four specific cases covered with increasing complexity:
|
|||
state for client agent's RPC client.
|
||||
- [ ] Add a test to `agent/agent_test.go` similar to others with prefix
|
||||
`TestAgent_reloadConfig*`.
|
||||
- [ ] Add documentation to `website/content/docs/agent/config/agent-config-files.mdx`.
|
||||
- [ ] Add documentation to `website/content/docs/agent/config/config-files.mdx`.
|
||||
|
||||
Done! You can now use your new field in a client agent by accessing
|
||||
`s.agent.Config.<FieldName>`.
|
||||
|
@ -75,7 +75,7 @@ If the config field also needs a CLI flag, then follow these steps.
|
|||
`TestLoad_IntegrationWithFlags` in `agent/config/runtime_test.go` to ensure setting the
|
||||
flag works.
|
||||
- [ ] Add flag (as well as config file) documentation to
|
||||
`website/source/docs/agent/config/agent-config-files.mdx` and `website/source/docs/agent/config/agent-config-cli.mdx`.
|
||||
`website/source/docs/agent/config/config-files.mdx` and `website/source/docs/agent/config/cli-flags.mdx`.
|
||||
|
||||
## Adding a Simple Config Field for Servers
|
||||
Consul servers have a separate Config struct for reasons. Note that Consul
|
||||
|
|
|
@ -22,7 +22,7 @@ The "RPC Server" accepts requests to the [server port] and routes the requests b
|
|||
configuration of the Server and the the first byte in the request. The diagram below shows
|
||||
all the possible routing flows.
|
||||
|
||||
[server port]: https://www.consul.io/docs/agent/config/agent-config-files#server_rpc_port
|
||||
[server port]: https://www.consul.io/docs/agent/config/config-files#server_rpc_port
|
||||
|
||||
![RPC Routing](./routing.svg)
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@ the [ACL tutorial](https://learn.hashicorp.com/tutorials/consul/access-control-s
|
|||
## Bootstrap ACLs
|
||||
|
||||
This endpoint does a special one-time bootstrap of the ACL system, making the first
|
||||
management token if the [`acl.tokens.initial_management`](/docs/agent/config/agent-config-files#acl_tokens_initial_management)
|
||||
management token if the [`acl.tokens.initial_management`](/docs/agent/config/config-files#acl_tokens_initial_management)
|
||||
configuration entry is not specified in the Consul server configuration and if the
|
||||
cluster has not been bootstrapped previously. This is available in Consul 0.9.1 and later,
|
||||
and requires all Consul servers to be upgraded in order to operate.
|
||||
|
@ -141,7 +141,7 @@ $ curl \
|
|||
|
||||
- `SourceDatacenter` - The authoritative ACL datacenter that ACLs are being
|
||||
replicated from and will match the
|
||||
[`primary_datacenter`](/docs/agent/config/agent-config-files#primary_datacenter) configuration.
|
||||
[`primary_datacenter`](/docs/agent/config/config-files#primary_datacenter) configuration.
|
||||
|
||||
- `ReplicationType` - The type of replication that is currently in use.
|
||||
|
||||
|
@ -289,7 +289,7 @@ The table below shows this endpoint's support for
|
|||
|
||||
-> **Note** - To use the login process to create tokens in any connected
|
||||
secondary datacenter, [ACL
|
||||
replication](/docs/agent/config/agent-config-files#acl_enable_token_replication) must be
|
||||
replication](/docs/agent/config/config-files#acl_enable_token_replication) must be
|
||||
enabled. Login requires the ability to create local tokens which is restricted
|
||||
to the primary datacenter and any secondary datacenters with ACL token
|
||||
replication enabled.
|
||||
|
@ -415,7 +415,7 @@ The table below shows this endpoint's support for
|
|||
|
||||
-> **Note** - To use the login process to create tokens in any connected
|
||||
secondary datacenter, [ACL
|
||||
replication](/docs/agent/config/agent-config-files#acl_enable_token_replication) must be
|
||||
replication](/docs/agent/config/config-files#acl_enable_token_replication) must be
|
||||
enabled. Login requires the ability to create local tokens which is restricted
|
||||
to the primary datacenter and any secondary datacenters with ACL token
|
||||
replication enabled.
|
||||
|
@ -495,7 +495,7 @@ The table below shows this endpoint's support for
|
|||
|
||||
-> **Note** - To use the login process to create tokens in any connected
|
||||
secondary datacenter, [ACL
|
||||
replication](/docs/agent/config/agent-config-files#acl_enable_token_replication) must be
|
||||
replication](/docs/agent/config/config-files#acl_enable_token_replication) must be
|
||||
enabled. Login requires the ability to create local tokens which is restricted
|
||||
to the primary datacenter and any secondary datacenters with ACL token
|
||||
replication enabled.
|
||||
|
|
|
@ -432,7 +432,7 @@ page.
|
|||
|
||||
In order to enable [Prometheus](https://prometheus.io/) support, you need to use the
|
||||
configuration directive
|
||||
[`prometheus_retention_time`](/docs/agent/config/agent-config-files#telemetry-prometheus_retention_time).
|
||||
[`prometheus_retention_time`](/docs/agent/config/config-files#telemetry-prometheus_retention_time).
|
||||
|
||||
Since Consul 1.7.2 this endpoint will also automatically switch output format if
|
||||
the request contains an `Accept` header with a compatible MIME type such as
|
||||
|
@ -731,7 +731,7 @@ $ curl \
|
|||
This endpoint updates the ACL tokens currently in use by the agent. It can be
|
||||
used to introduce ACL tokens to the agent for the first time, or to update
|
||||
tokens that were initially loaded from the agent's configuration. Tokens will be persisted
|
||||
only if the [`acl.enable_token_persistence`](/docs/agent/config/agent-config-files#acl_enable_token_persistence)
|
||||
only if the [`acl.enable_token_persistence`](/docs/agent/config/config-files#acl_enable_token_persistence)
|
||||
configuration is `true`. When not being persisted, they will need to be reset if the agent
|
||||
is restarted.
|
||||
|
||||
|
@ -743,9 +743,9 @@ is restarted.
|
|||
| `PUT` | `/agent/token/replication` | `application/json` |
|
||||
|
||||
The paths above correspond to the token names as found in the agent configuration:
|
||||
[`default`](/docs/agent/config/agent-config-files#acl_tokens_default), [`agent`](/docs/agent/config/agent-config-files#acl_tokens_agent),
|
||||
[`agent_recovery`](/docs/agent/config/agent-config-files#acl_tokens_agent_recovery), and
|
||||
[`replication`](/docs/agent/config/agent-config-files#acl_tokens_replication).
|
||||
[`default`](/docs/agent/config/config-files#acl_tokens_default), [`agent`](/docs/agent/config/config-files#acl_tokens_agent),
|
||||
[`agent_recovery`](/docs/agent/config/config-files#acl_tokens_agent_recovery), and
|
||||
[`replication`](/docs/agent/config/config-files#acl_tokens_replication).
|
||||
|
||||
-> **Deprecation Note:** The following paths were deprecated in version 1.11
|
||||
|
||||
|
@ -754,7 +754,7 @@ The paths above correspond to the token names as found in the agent configuratio
|
|||
| `PUT` | `/agent/token/agent_master` | `application/json` |
|
||||
|
||||
The paths above correspond to the token names as found in the agent configuration:
|
||||
[`agent_master`](/docs/agent/config/agent-config-files#acl_tokens_agent_master).
|
||||
[`agent_master`](/docs/agent/config/config-files#acl_tokens_agent_master).
|
||||
|
||||
-> **Deprecation Note:** The following paths were deprecated in version 1.4.3
|
||||
|
||||
|
@ -766,9 +766,9 @@ The paths above correspond to the token names as found in the agent configuratio
|
|||
| `PUT` | `/agent/token/acl_replication_token` | `application/json` |
|
||||
|
||||
The paths above correspond to the token names as found in the agent configuration:
|
||||
[`acl_token`](/docs/agent/config/agent-config-files#acl_token_legacy), [`acl_agent_token`](/docs/agent/config/agent-config-files#acl_agent_token_legacy),
|
||||
[`acl_agent_master_token`](/docs/agent/config/agent-config-files#acl_agent_master_token_legacy), and
|
||||
[`acl_replication_token`](/docs/agent/config/agent-config-files#acl_replication_token_legacy).
|
||||
[`acl_token`](/docs/agent/config/config-files#acl_token_legacy), [`acl_agent_token`](/docs/agent/config/config-files#acl_agent_token_legacy),
|
||||
[`acl_agent_master_token`](/docs/agent/config/config-files#acl_agent_master_token_legacy), and
|
||||
[`acl_replication_token`](/docs/agent/config/config-files#acl_replication_token_legacy).
|
||||
|
||||
The table below shows this endpoint's support for
|
||||
[blocking queries](/api/features/blocking),
|
||||
|
|
|
@ -10,7 +10,7 @@ description: |-
|
|||
|
||||
The `/config` endpoints create, update, delete and query central configuration
|
||||
entries registered with Consul. See the
|
||||
[agent configuration](/docs/agent/config/agent-config-files#enable_central_service_config)
|
||||
[agent configuration](/docs/agent/config/config-files#enable_central_service_config)
|
||||
for more information on how to enable this functionality for centrally
|
||||
configuring services and [configuration entries docs](/docs/agent/config-entries) for a description
|
||||
of the configuration entries content.
|
||||
|
|
|
@ -94,7 +94,7 @@ The table below shows this endpoint's support for
|
|||
evaluation. As with L4 intentions, traffic that fails to match any of the
|
||||
provided permissions in this intention will be subject to the default
|
||||
intention behavior is defined by the default [ACL
|
||||
policy](/docs/agent/config/agent-config-files#acl_default_policy).
|
||||
policy](/docs/agent/config/config-files#acl_default_policy).
|
||||
|
||||
This should be omitted for an L4 intention as it is mutually exclusive with
|
||||
the `Action` field.
|
||||
|
|
|
@ -235,7 +235,7 @@ The table below shows this endpoint's support for
|
|||
ascending order based on the estimated round trip time from that node. Passing
|
||||
`?near=_agent` will use the agent's node for the sort. This is specified as
|
||||
part of the URL as a query parameter. **Note** that using `near` will ignore
|
||||
[`use_streaming_backend`](/docs/agent/config/agent-config-files#use_streaming_backend) and always
|
||||
[`use_streaming_backend`](/docs/agent/config/config-files#use_streaming_backend) and always
|
||||
use blocking queries, because the data required to sort the results is not available
|
||||
to the streaming backend.
|
||||
|
||||
|
|
|
@ -79,7 +79,7 @@ $ curl \
|
|||
|
||||
Consul 0.7 added the ability to translate addresses in HTTP response based on
|
||||
the configuration setting for
|
||||
[`translate_wan_addrs`](/docs/agent/config/agent-config-files#translate_wan_addrs). In order
|
||||
[`translate_wan_addrs`](/docs/agent/config/config-files#translate_wan_addrs). In order
|
||||
to allow clients to know if address translation is in effect, the
|
||||
`X-Consul-Translate-Addresses` header will be added if translation is enabled,
|
||||
and will have a value of `true`. If translation is not enabled then this header
|
||||
|
@ -90,7 +90,7 @@ will not be present.
|
|||
All API responses for Consul versions after 1.9 will include an HTTP response
|
||||
header `X-Consul-Default-ACL-Policy` set to either "allow" or "deny" which
|
||||
mirrors the current value of the agent's
|
||||
[`acl.default_policy`](/docs/agent/config/agent-config-files#acl_default_policy) option.
|
||||
[`acl.default_policy`](/docs/agent/config/config-files#acl_default_policy) option.
|
||||
|
||||
This is also the default [intention](/docs/connect/intentions) enforcement
|
||||
action if no intention matches.
|
||||
|
|
|
@ -67,7 +67,7 @@ $ curl \
|
|||
```
|
||||
|
||||
For more information about the Autopilot configuration options, see the
|
||||
[agent configuration section](/docs/agent/config/agent-config-files#autopilot).
|
||||
[agent configuration section](/docs/agent/config/config-files#autopilot).
|
||||
|
||||
## Update Configuration
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@ Command: `consul acl set-agent-token`
|
|||
This command updates the ACL tokens currently in use by the agent. It can be used to introduce
|
||||
ACL tokens to the agent for the first time, or to update tokens that were initially loaded from
|
||||
the agent's configuration. Tokens are not persisted unless
|
||||
[`acl.enable_token_persistence`](/docs/agent/config/agent-config-files#acl_enable_token_persistence)
|
||||
[`acl.enable_token_persistence`](/docs/agent/config/config-files#acl_enable_token_persistence)
|
||||
is `true`, so tokens will need to be updated again if that option is `false` and
|
||||
the agent is restarted.
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@ Command: `consul config`
|
|||
The `config` command is used to interact with Consul's central configuration
|
||||
system. It exposes commands for creating, updating, reading, and deleting
|
||||
different kinds of config entries. See the
|
||||
[agent configuration](/docs/agent/config/agent-config-files#enable_central_service_config)
|
||||
[agent configuration](/docs/agent/config/config-files#enable_central_service_config)
|
||||
for more information on how to enable this functionality for centrally
|
||||
configuring services and [configuration entries docs](/docs/agent/config-entries) for a description
|
||||
of the configuration entries content.
|
||||
|
|
|
@ -42,7 +42,7 @@ proxy configuration needed.
|
|||
be used instead. The scheme can also be set to HTTPS by setting the
|
||||
environment variable CONSUL_HTTP_SSL=true. This may be a unix domain socket
|
||||
using `unix:///path/to/socket` if the [agent is configured to
|
||||
listen](/docs/agent/config/agent-config-files#addresses) that way.
|
||||
listen](/docs/agent/config/config-files#addresses) that way.
|
||||
|
||||
-> **Note:** gRPC uses the same TLS
|
||||
settings as the HTTPS API. If HTTPS is enabled then gRPC will require HTTPS
|
||||
|
|
|
@ -78,7 +78,7 @@ information when `debug` is running. By default, it captures all information.
|
|||
| `members` | A list of all the WAN and LAN members in the cluster. |
|
||||
| `metrics` | Metrics from the in-memory metrics endpoint in the target, captured at the interval. |
|
||||
| `logs` | `DEBUG` level logs for the target agent, captured for the duration. |
|
||||
| `pprof` | Golang heap, CPU, goroutine, and trace profiling. CPU and traces are captured for `duration` in a single file while heap and goroutine are separate snapshots for each `interval`. This information is not retrieved unless [`enable_debug`](/docs/agent/config/agent-config-files#enable_debug) is set to `true` on the target agent or ACLs are enable and an ACL token with `operator:read` is provided. |
|
||||
| `pprof` | Golang heap, CPU, goroutine, and trace profiling. CPU and traces are captured for `duration` in a single file while heap and goroutine are separate snapshots for each `interval`. This information is not retrieved unless [`enable_debug`](/docs/agent/config/config-files#enable_debug) is set to `true` on the target agent or ACLs are enable and an ACL token with `operator:read` is provided. |
|
||||
|
||||
## Examples
|
||||
|
||||
|
|
|
@ -226,7 +226,7 @@ CONSUL_TLS_SERVER_NAME=consulserver.domain
|
|||
Like [`CONSUL_HTTP_ADDR`](#consul_http_addr) but configures the address the
|
||||
local agent is listening for gRPC requests. Currently gRPC is only used for
|
||||
integrating [Envoy proxy](/docs/connect/proxies/envoy) and must be [enabled
|
||||
explicitly](/docs/agent/config/agent-config-files#grpc_port) in agent configuration.
|
||||
explicitly](/docs/agent/config/config-files#grpc_port) in agent configuration.
|
||||
|
||||
```
|
||||
CONSUL_GRPC_ADDR=127.0.0.1:8502
|
||||
|
|
|
@ -84,10 +84,10 @@ Usage: `consul operator autopilot set-config [options]`
|
|||
- `-disable-upgrade-migration` <EnterpriseAlert inline /> - Controls whether Consul will avoid promoting
|
||||
new servers until it can perform a migration. Must be one of `[true|false]`.
|
||||
|
||||
- `-redundancy-zone-tag` <EnterpriseAlert inline /> - Controls the [`-node-meta`](/docs/agent/config/agent-config-cli#_node_meta)
|
||||
- `-redundancy-zone-tag` <EnterpriseAlert inline /> - Controls the [`-node-meta`](/docs/agent/config/cli-flags#_node_meta)
|
||||
key name used for separating servers into different redundancy zones.
|
||||
|
||||
- `-upgrade-version-tag` <EnterpriseAlert inline /> - Controls the [`-node-meta`](/docs/agent/config/agent-config-cli#_node_meta)
|
||||
- `-upgrade-version-tag` <EnterpriseAlert inline /> - Controls the [`-node-meta`](/docs/agent/config/cli-flags#_node_meta)
|
||||
tag to use for version info when performing upgrade migrations. If left blank, the Consul version will be used.
|
||||
|
||||
### Command Output
|
||||
|
|
|
@ -21,7 +21,7 @@ to be loaded by the agent. This command cannot operate on partial
|
|||
configuration fragments since those won't pass the full agent validation.
|
||||
|
||||
For more information on the format of Consul's configuration files, read the
|
||||
consul agent [Configuration Files](/docs/agent/config/agent-config-files)
|
||||
consul agent [Configuration Files](/docs/agent/config/config-files)
|
||||
section.
|
||||
|
||||
## Usage
|
||||
|
|
|
@ -52,7 +52,7 @@ Configuration entries outside of Kubernetes should be managed with the Consul
|
|||
[CLI](/commands/config) or [API](/api/config). Additionally, as a
|
||||
convenience for initial cluster bootstrapping, configuration entries can be
|
||||
specified in all of the Consul servers's
|
||||
[configuration files](/docs/agent/config/agent-config-files#config_entries_bootstrap)
|
||||
[configuration files](/docs/agent/config/config-files#config_entries_bootstrap)
|
||||
|
||||
### Managing Configuration Entries with the CLI
|
||||
|
||||
|
@ -156,7 +156,7 @@ api
|
|||
### Bootstrapping From A Configuration File
|
||||
|
||||
Configuration entries can be bootstrapped by adding them [inline to each Consul
|
||||
server's configuration file](/docs/agent/config/agent-config-files#config_entries). When a
|
||||
server's configuration file](/docs/agent/config/config-files#config_entries). When a
|
||||
server gains leadership, it will attempt to initialize the configuration entries.
|
||||
If a configuration entry does not already exist outside of the servers
|
||||
configuration, then it will create it. If a configuration entry does exist, that
|
||||
|
|
|
@ -7,7 +7,7 @@ description: >-
|
|||
|
||||
# Command-line Options ((#commandline_options))
|
||||
|
||||
-> **Note:** Some CLI arguments may be different from HCL keys. See [Configuration Key Reference](/docs/agent/config/agent-config-files#config_key_reference) for equivalent HCL Keys.
|
||||
-> **Note:** Some CLI arguments may be different from HCL keys. See [Configuration Key Reference](/docs/agent/config/config-files#config_key_reference) for equivalent HCL Keys.
|
||||
|
||||
This topic describes the available command-line options for the Consul agent.
|
||||
|
||||
|
@ -30,7 +30,7 @@ information.
|
|||
limit of 4k for maximum size of checks, this is a positive value. By limiting this
|
||||
size, it allows to put less pressure on Consul servers when many checks are having
|
||||
a very large output in their checks. In order to completely disable check output
|
||||
capture, it is possible to use [`discard_check_output`](/docs/agent/config/agent-config-files#discard_check_output).
|
||||
capture, it is possible to use [`discard_check_output`](/docs/agent/config/config-files#discard_check_output).
|
||||
|
||||
- `-client` ((#\_client)) - The address to which Consul will bind client
|
||||
interfaces, including the HTTP and DNS servers. By default, this is "127.0.0.1",
|
||||
|
@ -126,7 +126,7 @@ information.
|
|||
|
||||
- `-raft-protocol` ((#\_raft_protocol)) - This controls the internal version
|
||||
of the Raft consensus protocol used for server communications. This must be set
|
||||
to 3 in order to gain access to Autopilot features, with the exception of [`cleanup_dead_servers`](/docs/agent/config/agent-config-files#cleanup_dead_servers). Defaults to 3 in Consul 1.0.0 and later (defaulted to 2 previously). See [Raft Protocol Version Compatibility](/docs/upgrade-specific#raft-protocol-version-compatibility) for more details.
|
||||
to 3 in order to gain access to Autopilot features, with the exception of [`cleanup_dead_servers`](/docs/agent/config/config-files#cleanup_dead_servers). Defaults to 3 in Consul 1.0.0 and later (defaulted to 2 previously). See [Raft Protocol Version Compatibility](/docs/upgrade-specific#raft-protocol-version-compatibility) for more details.
|
||||
|
||||
- `-segment` ((#\_segment)) <EnterpriseAlert inline /> - This flag is used to set
|
||||
the name of the network segment the agent belongs to. An agent can only join and
|
||||
|
@ -150,13 +150,13 @@ information.
|
|||
|
||||
- `-advertise-wan` ((#\_advertise-wan)) - The advertise WAN address is used
|
||||
to change the address that we advertise to server nodes joining through the WAN.
|
||||
This can also be set on client agents when used in combination with the [`translate_wan_addrs`](/docs/agent/config/agent-config-files#translate_wan_addrs) configuration option. By default, the [`-advertise`](#_advertise) address
|
||||
This can also be set on client agents when used in combination with the [`translate_wan_addrs`](/docs/agent/config/config-files#translate_wan_addrs) configuration option. By default, the [`-advertise`](#_advertise) address
|
||||
is advertised. However, in some cases all members of all datacenters cannot be
|
||||
on the same physical or virtual network, especially on hybrid setups mixing cloud
|
||||
and private datacenters. This flag enables server nodes gossiping through the public
|
||||
network for the WAN while using private VLANs for gossiping to each other and their
|
||||
client agents, and it allows client agents to be reached at this address when being
|
||||
accessed from a remote datacenter if the remote datacenter is configured with [`translate_wan_addrs`](/docs/agent/config/agent-config-files#translate_wan_addrs). In Consul 1.1.0 and later this can be dynamically defined with a [go-sockaddr]
|
||||
accessed from a remote datacenter if the remote datacenter is configured with [`translate_wan_addrs`](/docs/agent/config/config-files#translate_wan_addrs). In Consul 1.1.0 and later this can be dynamically defined with a [go-sockaddr]
|
||||
template that is resolved at runtime.
|
||||
|
||||
## Address Bind Options
|
||||
|
@ -294,7 +294,7 @@ information.
|
|||
|
||||
If Consul is running on the non-default Serf LAN port, the port must
|
||||
be specified in the join address, or configured as the agent's default Serf port
|
||||
using the [`ports.serf_lan`](/docs/agent/config/agent-config-files#serf_lan_port) configuration option or
|
||||
using the [`ports.serf_lan`](/docs/agent/config/config-files#serf_lan_port) configuration option or
|
||||
[`-serf-lan-port`](#_serf_lan_port) command line flag.
|
||||
|
||||
If using network segments (Enterprise), see [additional documentation on
|
|
@ -82,7 +82,7 @@ Valid time units are 'ns', 'us' (or 'µs'), 'ms', 's', 'm', 'h'."
|
|||
- `https` - The HTTPS API. Defaults to `client_addr`
|
||||
- `grpc` - The gRPC API. Defaults to `client_addr`
|
||||
|
||||
- `alt_domain` Equivalent to the [`-alt-domain` command-line flag](/docs/agent/config/agent-config-cli#_alt_domain)
|
||||
- `alt_domain` Equivalent to the [`-alt-domain` command-line flag](/docs/agent/config/cli-flags#_alt_domain)
|
||||
|
||||
- `audit` <EnterpriseAlert inline /> - Added in Consul 1.8, the audit object allow users to enable auditing
|
||||
and configure a sink and filters for their audit logs. For more information, review the [audit log tutorial](https://learn.hashicorp.com/tutorials/consul/audit-logging).
|
||||
|
@ -209,7 +209,7 @@ Valid time units are 'ns', 'us' (or 'µs'), 'ms', 's', 'm', 'h'."
|
|||
|
||||
- `server_addresses` (Defaults to `[]`) This specifies the addresses of servers in
|
||||
the local datacenter to use for the initial RPC. These addresses support
|
||||
[Cloud Auto-Joining](/docs/agent/config/agent-config-cli#cloud-auto-joining) and can optionally include a port to
|
||||
[Cloud Auto-Joining](/docs/agent/config/cli-flags#cloud-auto-joining) and can optionally include a port to
|
||||
use when making the outbound connection. If not port is provided the `server_port`
|
||||
will be used.
|
||||
|
||||
|
@ -312,7 +312,7 @@ Valid time units are 'ns', 'us' (or 'µs'), 'ms', 's', 'm', 'h'."
|
|||
|
||||
- `partition` <EnterpriseAlert inline /> - The admin partition name the client is requesting.
|
||||
|
||||
- `bind_addr` Equivalent to the [`-bind` command-line flag](/docs/agent/config/agent-config-cli#_bind).
|
||||
- `bind_addr` Equivalent to the [`-bind` command-line flag](/docs/agent/config/cli-flags#_bind).
|
||||
|
||||
This parameter can be set to a go-sockaddr template that resolves to a single
|
||||
address. Special characters such as backslashes `\` or double quotes `"`
|
||||
|
@ -360,7 +360,7 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
changes state, the new state and associated output is synchronized immediately.
|
||||
To disable this behavior, set the value to "0s".
|
||||
|
||||
- `client_addr` Equivalent to the [`-client` command-line flag](/docs/agent/config/agent-config-cli#_client).
|
||||
- `client_addr` Equivalent to the [`-client` command-line flag](/docs/agent/config/cli-flags#_client).
|
||||
|
||||
- `config_entries` This object allows setting options for centralized config entries.
|
||||
|
||||
|
@ -374,9 +374,9 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
See the [configuration entry docs](/docs/agent/config-entries) for more
|
||||
details about the contents of each entry.
|
||||
|
||||
- `datacenter` Equivalent to the [`-datacenter` command-line flag](/docs/agent/config/agent-config-cli#_datacenter).
|
||||
- `datacenter` Equivalent to the [`-datacenter` command-line flag](/docs/agent/config/cli-flags#_datacenter).
|
||||
|
||||
- `data_dir` Equivalent to the [`-data-dir` command-line flag](/docs/agent/config/agent-config-cli#_data_dir).
|
||||
- `data_dir` Equivalent to the [`-data-dir` command-line flag](/docs/agent/config/cli-flags#_data_dir).
|
||||
|
||||
- `disable_anonymous_signature` Disables providing an anonymous
|
||||
signature for de-duplication with the update check. See [`disable_update_check`](#disable_update_check).
|
||||
|
@ -406,17 +406,17 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
- `enable_debug` When set, enables some additional debugging features. Currently, this is only used to
|
||||
access runtime profiling HTTP endpoints, which are available with an `operator:read` ACL regardless of the value of `enable_debug`.
|
||||
|
||||
- `enable_script_checks` Equivalent to the [`-enable-script-checks` command-line flag](/docs/agent/config/agent-config-cli#_enable_script_checks).
|
||||
- `enable_script_checks` Equivalent to the [`-enable-script-checks` command-line flag](/docs/agent/config/cli-flags#_enable_script_checks).
|
||||
|
||||
ACLs must be enabled for agents and the `enable_script_checks` option must be set to `true` to enable script checks in Consul 0.9.0 and later. See [Registering and Querying Node Information](/docs/security/acl/acl-rules#registering-and-querying-node-information) for related information.
|
||||
|
||||
~> **Security Warning:** Enabling script checks in some configurations may introduce a known remote execution vulnerability targeted by malware. We strongly recommend `enable_local_script_checks` instead. Refer to the following article for additional guidance: [_Protecting Consul from RCE Risk in Specific Configurations_](https://www.hashicorp.com/blog/protecting-consul-from-rce-risk-in-specific-configurations)
|
||||
for more details.
|
||||
|
||||
- `enable_local_script_checks` Equivalent to the [`-enable-local-script-checks` command-line flag](/docs/agent/config/agent-config-cli#_enable_local_script_checks).
|
||||
- `enable_local_script_checks` Equivalent to the [`-enable-local-script-checks` command-line flag](/docs/agent/config/cli-flags#_enable_local_script_checks).
|
||||
|
||||
- `disable_keyring_file` - Equivalent to the
|
||||
[`-disable-keyring-file` command-line flag](/docs/agent/config/agent-config-cli#_disable_keyring_file).
|
||||
[`-disable-keyring-file` command-line flag](/docs/agent/config/cli-flags#_disable_keyring_file).
|
||||
|
||||
- `disable_coordinates` - Disables sending of [network coordinates](/docs/architecture/coordinates).
|
||||
When network coordinates are disabled the `near` query param will not work to sort the nodes,
|
||||
|
@ -476,9 +476,9 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
- `kv_max_value_size` - **(Advanced)** Configures the maximum number of bytes for a kv request body to the [`/v1/kv`](/api/kv) endpoint. This limit defaults to [raft's](https://github.com/hashicorp/raft) suggested max size (512KB). **Note that tuning these improperly can cause Consul to fail in unexpected ways**, it may potentially affect leadership stability and prevent timely heartbeat signals by increasing RPC IO duration. This option affects the txn endpoint too, but Consul 1.7.2 introduced `txn_max_req_len` which is the preferred way to set the limit for the txn endpoint. If both limits are set, the higher one takes precedence.
|
||||
- `txn_max_req_len` - **(Advanced)** Configures the maximum number of bytes for a transaction request body to the [`/v1/txn`](/api/txn) endpoint. This limit defaults to [raft's](https://github.com/hashicorp/raft) suggested max size (512KB). **Note that tuning these improperly can cause Consul to fail in unexpected ways**, it may potentially affect leadership stability and prevent timely heartbeat signals by increasing RPC IO duration.
|
||||
|
||||
- `default_query_time` Equivalent to the [`-default-query-time` command-line flag](/docs/agent/config/agent-config-cli#_default_query_time).
|
||||
- `default_query_time` Equivalent to the [`-default-query-time` command-line flag](/docs/agent/config/cli-flags#_default_query_time).
|
||||
|
||||
- `max_query_time` Equivalent to the [`-max-query-time` command-line flag](/docs/agent/config/agent-config-cli#_max_query_time).
|
||||
- `max_query_time` Equivalent to the [`-max-query-time` command-line flag](/docs/agent/config/cli-flags#_max_query_time).
|
||||
|
||||
- `partition` <EnterpriseAlert inline /> - This flag is used to set
|
||||
the name of the admin partition the agent belongs to. An agent can only join
|
||||
|
@ -559,7 +559,7 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
enforcement of ACLs.
|
||||
|
||||
- `primary_gateways` Equivalent to the [`-primary-gateway`
|
||||
command-line flag](/docs/agent/config/agent-config-cli#_primary_gateway). Takes a list of addresses to use as the
|
||||
command-line flag](/docs/agent/config/cli-flags#_primary_gateway). Takes a list of addresses to use as the
|
||||
mesh gateways for the primary datacenter when authoritative replicated catalog
|
||||
data is not present. Discovery happens every [`primary_gateways_interval`](#primary_gateways_interval)
|
||||
until at least one primary mesh gateway is discovered. This was added in Consul
|
||||
|
@ -570,7 +570,7 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
30s. This was added in Consul 1.8.0.
|
||||
|
||||
- `protocol` ((#protocol)) Equivalent to the [`-protocol` command-line
|
||||
flag](/docs/agent/config/agent-config-cli#_protocol).
|
||||
flag](/docs/agent/config/cli-flags#_protocol).
|
||||
|
||||
- `reap` This controls Consul's automatic reaping of child processes,
|
||||
which is useful if Consul is running as PID 1 in a Docker container. If this isn't
|
||||
|
@ -612,7 +612,7 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
servers in all federated datacenters must have this enabled before any client can use
|
||||
[`use_streaming_backend`](#use_streaming_backend).
|
||||
|
||||
- `segment` <EnterpriseAlert inline /> - Equivalent to the [`-segment` command-line flag](/docs/agent/config/agent-config-cli#_segment).
|
||||
- `segment` <EnterpriseAlert inline /> - Equivalent to the [`-segment` command-line flag](/docs/agent/config/cli-flags#_segment).
|
||||
|
||||
~> **Warning:** The `segment` option cannot be used with the [`partition`](#partition-1) option.
|
||||
|
||||
|
@ -635,11 +635,11 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
port. Only valid if the segment's bind address differs from the [`-bind`](#_bind)
|
||||
address. Defaults to false.
|
||||
|
||||
- `server` Equivalent to the [`-server` command-line flag](/docs/agent/config/agent-config-cli#_server).
|
||||
- `server` Equivalent to the [`-server` command-line flag](/docs/agent/config/cli-flags#_server).
|
||||
|
||||
- `non_voting_server` - **This field is deprecated in Consul 1.9.1. See the [`read_replica`](#read_replica) field instead.**
|
||||
|
||||
- `read_replica` - Equivalent to the [`-read-replica` command-line flag](/docs/agent/config/agent-config-cli#_read_replica).
|
||||
- `read_replica` - Equivalent to the [`-read-replica` command-line flag](/docs/agent/config/cli-flags#_read_replica).
|
||||
|
||||
- `session_ttl_min` The minimum allowed session TTL. This ensures sessions are not created with TTL's
|
||||
shorter than the specified limit. It is recommended to keep this limit at or above
|
||||
|
@ -907,7 +907,7 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
set [`acl.enable_token_replication`](#acl_enable_token_replication) to true for backward compatibility.
|
||||
|
||||
If there's a partition or other outage affecting the authoritative datacenter, and the
|
||||
[`acl_down_policy`](/docs/agent/config/agent-config-files#acl_down_policy) is set to "extend-cache", tokens not
|
||||
[`acl_down_policy`](/docs/agent/config/config-files#acl_down_policy) is set to "extend-cache", tokens not
|
||||
in the cache can be resolved during the outage using the replicated set of ACLs.
|
||||
|
||||
- `acl_token` ((#acl_token_legacy)) - **Deprecated in Consul 1.4.0. See
|
||||
|
@ -937,13 +937,13 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
|
||||
## Advertise Address Parameters
|
||||
|
||||
- `advertise_addr` Equivalent to the [`-advertise` command-line flag](/docs/agent/config/agent-config-cli#_advertise).
|
||||
- `advertise_addr` Equivalent to the [`-advertise` command-line flag](/docs/agent/config/cli-flags#_advertise).
|
||||
|
||||
- `advertise_addr_ipv4` This was added together with [`advertise_addr_ipv6`](#advertise_addr_ipv6) to support dual stack IPv4/IPv6 environments. Using this, both IPv4 and IPv6 addresses can be specified and requested during eg service discovery.
|
||||
|
||||
- `advertise_addr_ipv6` This was added together with [`advertise_addr_ipv4`](#advertise_addr_ipv4) to support dual stack IPv4/IPv6 environments. Using this, both IPv4 and IPv6 addresses can be specified and requested during eg service discovery.
|
||||
|
||||
- `advertise_addr_wan` Equivalent to the [`-advertise-wan` command-line flag](/docs/agent/config/agent-config-cli#_advertise-wan).
|
||||
- `advertise_addr_wan` Equivalent to the [`-advertise-wan` command-line flag](/docs/agent/config/cli-flags#_advertise-wan).
|
||||
|
||||
- `advertise_addr_wan_ipv4` This was added together with [`advertise_addr_wan_ipv6`](#advertise_addr_wan_ipv6) to support dual stack IPv4/IPv6 environments. Using this, both IPv4 and IPv6 addresses can be specified and requested during eg service discovery.
|
||||
|
||||
|
@ -956,9 +956,9 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
|
||||
## Bootstrap Parameters
|
||||
|
||||
- `bootstrap` Equivalent to the [`-bootstrap` command-line flag](/docs/agent/config/agent-config-cli#_bootstrap).
|
||||
- `bootstrap` Equivalent to the [`-bootstrap` command-line flag](/docs/agent/config/cli-flags#_bootstrap).
|
||||
|
||||
- `bootstrap_expect` Equivalent to the [`-bootstrap-expect` command-line flag](/docs/agent/config/agent-config-cli#_bootstrap_expect).
|
||||
- `bootstrap_expect` Equivalent to the [`-bootstrap-expect` command-line flag](/docs/agent/config/cli-flags#_bootstrap_expect).
|
||||
|
||||
## Connect Parameters
|
||||
|
||||
|
@ -1230,7 +1230,7 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
versions and will assume the label is the datacenter. See: [this section](/docs/discovery/dns#namespaced-services)
|
||||
for more details.
|
||||
|
||||
- `domain` Equivalent to the [`-domain` command-line flag](/docs/agent/config/agent-config-cli#_domain).
|
||||
- `domain` Equivalent to the [`-domain` command-line flag](/docs/agent/config/cli-flags#_domain).
|
||||
|
||||
## Encryption Parameters
|
||||
|
||||
|
@ -1273,7 +1273,7 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
the certificates requested by `auto_encrypt` from the server have these `ip_san`
|
||||
set as IP SAN.
|
||||
|
||||
- `encrypt` Equivalent to the [`-encrypt` command-line flag](/docs/agent/config/agent-config-cli#_encrypt).
|
||||
- `encrypt` Equivalent to the [`-encrypt` command-line flag](/docs/agent/config/cli-flags#_encrypt).
|
||||
|
||||
- `encrypt_verify_incoming` - This is an optional
|
||||
parameter that can be used to disable enforcing encryption for incoming gossip
|
||||
|
@ -1375,15 +1375,15 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
|
||||
## Join Parameters
|
||||
|
||||
- `rejoin_after_leave` Equivalent to the [`-rejoin` command-line flag](/docs/agent/config/agent-config-cli#_rejoin).
|
||||
- `rejoin_after_leave` Equivalent to the [`-rejoin` command-line flag](/docs/agent/config/cli-flags#_rejoin).
|
||||
|
||||
- `retry_join` - Equivalent to the [`-retry-join`](/docs/agent/config/agent-config-cli#retry-join) command-line flag.
|
||||
- `retry_join` - Equivalent to the [`-retry-join`](/docs/agent/config/cli-flags#retry-join) command-line flag.
|
||||
|
||||
- `retry_interval` Equivalent to the [`-retry-interval` command-line flag](/docs/agent/config/agent-config-cli#_retry_interval).
|
||||
- `retry_interval` Equivalent to the [`-retry-interval` command-line flag](/docs/agent/config/cli-flags#_retry_interval).
|
||||
|
||||
- `retry_join_wan` Equivalent to the [`-retry-join-wan` command-line flag](/docs/agent/config/agent-config-cli#_retry_join_wan). Takes a list of addresses to attempt joining to WAN every [`retry_interval_wan`](#_retry_interval_wan) until at least one join works.
|
||||
- `retry_join_wan` Equivalent to the [`-retry-join-wan` command-line flag](/docs/agent/config/cli-flags#_retry_join_wan). Takes a list of addresses to attempt joining to WAN every [`retry_interval_wan`](#_retry_interval_wan) until at least one join works.
|
||||
|
||||
- `retry_interval_wan` Equivalent to the [`-retry-interval-wan` command-line flag](/docs/agent/config/agent-config-cli#_retry_interval_wan).
|
||||
- `retry_interval_wan` Equivalent to the [`-retry-interval-wan` command-line flag](/docs/agent/config/cli-flags#_retry_interval_wan).
|
||||
|
||||
- `start_join` An array of strings specifying addresses
|
||||
of nodes to [`-join`](#_join) upon startup. Note that using
|
||||
|
@ -1395,19 +1395,19 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
|
||||
## Log Parameters
|
||||
|
||||
- `log_file` Equivalent to the [`-log-file` command-line flag](/docs/agent/config/agent-config-cli#_log_file).
|
||||
- `log_file` Equivalent to the [`-log-file` command-line flag](/docs/agent/config/cli-flags#_log_file).
|
||||
|
||||
- `log_rotate_duration` Equivalent to the [`-log-rotate-duration` command-line flag](/docs/agent/config/agent-config-cli#_log_rotate_duration).
|
||||
- `log_rotate_duration` Equivalent to the [`-log-rotate-duration` command-line flag](/docs/agent/config/cli-flags#_log_rotate_duration).
|
||||
|
||||
- `log_rotate_bytes` Equivalent to the [`-log-rotate-bytes` command-line flag](/docs/agent/config/agent-config-cli#_log_rotate_bytes).
|
||||
- `log_rotate_bytes` Equivalent to the [`-log-rotate-bytes` command-line flag](/docs/agent/config/cli-flags#_log_rotate_bytes).
|
||||
|
||||
- `log_rotate_max_files` Equivalent to the [`-log-rotate-max-files` command-line flag](/docs/agent/config/agent-config-cli#_log_rotate_max_files).
|
||||
- `log_rotate_max_files` Equivalent to the [`-log-rotate-max-files` command-line flag](/docs/agent/config/cli-flags#_log_rotate_max_files).
|
||||
|
||||
- `log_level` Equivalent to the [`-log-level` command-line flag](/docs/agent/config/agent-config-cli#_log_level).
|
||||
- `log_level` Equivalent to the [`-log-level` command-line flag](/docs/agent/config/cli-flags#_log_level).
|
||||
|
||||
- `log_json` Equivalent to the [`-log-json` command-line flag](/docs/agent/config/agent-config-cli#_log_json).
|
||||
- `log_json` Equivalent to the [`-log-json` command-line flag](/docs/agent/config/cli-flags#_log_json).
|
||||
|
||||
- `enable_syslog` Equivalent to the [`-syslog` command-line flag](/docs/agent/config/agent-config-cli#_syslog).
|
||||
- `enable_syslog` Equivalent to the [`-syslog` command-line flag](/docs/agent/config/cli-flags#_syslog).
|
||||
|
||||
- `syslog_facility` When [`enable_syslog`](#enable_syslog)
|
||||
is provided, this controls to which facility messages are sent. By default, `LOCAL0`
|
||||
|
@ -1415,11 +1415,11 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
|
||||
## Node Parameters
|
||||
|
||||
- `node_id` Equivalent to the [`-node-id` command-line flag](/docs/agent/config/agent-config-cli#_node_id).
|
||||
- `node_id` Equivalent to the [`-node-id` command-line flag](/docs/agent/config/cli-flags#_node_id).
|
||||
|
||||
- `node_name` Equivalent to the [`-node` command-line flag](/docs/agent/config/agent-config-cli#_node).
|
||||
- `node_name` Equivalent to the [`-node` command-line flag](/docs/agent/config/cli-flags#_node).
|
||||
|
||||
- `node_meta` Available in Consul 0.7.3 and later, This object allows associating arbitrary metadata key/value pairs with the local node, which can then be used for filtering results from certain catalog endpoints. See the [`-node-meta` command-line flag](/docs/agent/config/agent-config-cli#_node_meta) for more information.
|
||||
- `node_meta` Available in Consul 0.7.3 and later, This object allows associating arbitrary metadata key/value pairs with the local node, which can then be used for filtering results from certain catalog endpoints. See the [`-node-meta` command-line flag](/docs/agent/config/cli-flags#_node_meta) for more information.
|
||||
|
||||
```json
|
||||
{
|
||||
|
@ -1429,7 +1429,7 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
}
|
||||
```
|
||||
|
||||
- `disable_host_node_id` Equivalent to the [`-disable-host-node-id` command-line flag](/docs/agent/config/agent-config-cli#_disable_host_node_id).
|
||||
- `disable_host_node_id` Equivalent to the [`-disable-host-node-id` command-line flag](/docs/agent/config/cli-flags#_disable_host_node_id).
|
||||
|
||||
## Raft Parameters
|
||||
|
||||
|
@ -1444,7 +1444,7 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
|
||||
|
||||
- `raft_protocol` ((#raft_protocol)) Equivalent to the [`-raft-protocol`
|
||||
command-line flag](/docs/agent/config/agent-config-cli#_raft_protocol).
|
||||
command-line flag](/docs/agent/config/cli-flags#_raft_protocol).
|
||||
|
||||
- `raft_snapshot_threshold` ((#\_raft_snapshot_threshold)) This controls the
|
||||
minimum number of raft commit entries between snapshots that are saved to
|
||||
|
@ -1493,14 +1493,14 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
|
||||
## Serf Parameters
|
||||
|
||||
- `serf_lan` ((#serf_lan_bind)) Equivalent to the [`-serf-lan-bind` command-line flag](/docs/agent/config/agent-config-cli#_serf_lan_bind).
|
||||
- `serf_lan` ((#serf_lan_bind)) Equivalent to the [`-serf-lan-bind` command-line flag](/docs/agent/config/cli-flags#_serf_lan_bind).
|
||||
This is an IP address, not to be confused with [`ports.serf_lan`](#serf_lan_port).
|
||||
|
||||
- `serf_lan_allowed_cidrs` ((#serf_lan_allowed_cidrs)) Equivalent to the [`-serf-lan-allowed-cidrs` command-line flag](/docs/agent/config/agent-config-cli#_serf_lan_allowed_cidrs).
|
||||
- `serf_lan_allowed_cidrs` ((#serf_lan_allowed_cidrs)) Equivalent to the [`-serf-lan-allowed-cidrs` command-line flag](/docs/agent/config/cli-flags#_serf_lan_allowed_cidrs).
|
||||
|
||||
- `serf_wan` ((#serf_wan_bind)) Equivalent to the [`-serf-wan-bind` command-line flag](/docs/agent/config/agent-config-cli#_serf_wan_bind).
|
||||
- `serf_wan` ((#serf_wan_bind)) Equivalent to the [`-serf-wan-bind` command-line flag](/docs/agent/config/cli-flags#_serf_wan_bind).
|
||||
|
||||
- `serf_wan_allowed_cidrs` ((#serf_wan_allowed_cidrs)) Equivalent to the [`-serf-wan-allowed-cidrs` command-line flag](/docs/agent/config/agent-config-cli#_serf_wan_allowed_cidrs).
|
||||
- `serf_wan_allowed_cidrs` ((#serf_wan_allowed_cidrs)) Equivalent to the [`-serf-wan-allowed-cidrs` command-line flag](/docs/agent/config/cli-flags#_serf_wan_allowed_cidrs).
|
||||
|
||||
## Telemetry Paramters
|
||||
|
||||
|
@ -1639,7 +1639,7 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
## UI Parameters
|
||||
|
||||
- `ui` - **This field is deprecated in Consul 1.9.0. See the [`ui_config.enabled`](#ui_config_enabled) field instead.**
|
||||
Equivalent to the [`-ui`](/docs/agent/config/agent-config-cli#_ui) command-line flag.
|
||||
Equivalent to the [`-ui`](/docs/agent/config/cli-flags#_ui) command-line flag.
|
||||
|
||||
- `ui_config` - This object allows a number of sub-keys to be set which controls
|
||||
the display or features available in the UI. Configuring the UI with this
|
||||
|
@ -1650,12 +1650,12 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
- `enabled` ((#ui_config_enabled)) - This enables the service of the web UI
|
||||
from this agent. Boolean value, defaults to false. In `-dev` mode this
|
||||
defaults to true. Replaces `ui` from before 1.9.0. Equivalent to the
|
||||
[`-ui`](/docs/agent/config/agent-config-cli#_ui) command-line flag.
|
||||
[`-ui`](/docs/agent/config/cli-flags#_ui) command-line flag.
|
||||
|
||||
- `dir` ((#ui_config_dir)) - This specifies that the web UI should be served
|
||||
from an external dir rather than the build in one. This allows for
|
||||
customization or development. Replaces `ui_dir` from before 1.9.0.
|
||||
Equivalent to the [`-ui-dir`](/docs/agent/config/agent-config-cli#_ui_dir) command-line flag.
|
||||
Equivalent to the [`-ui-dir`](/docs/agent/config/cli-flags#_ui_dir) command-line flag.
|
||||
|
||||
- `content_path` ((#ui_config_content_path)) - This specifies the HTTP path
|
||||
that the web UI should be served from. Defaults to `/ui/`. Equivalent to the
|
||||
|
@ -1764,7 +1764,7 @@ bind_addr = "{{ GetPrivateInterfaces | include \"network\" \"10.0.0.0/8\" | attr
|
|||
- `{{Datacenter}}` - Replaced with the current service's datacenter.
|
||||
|
||||
- `ui_dir` - **This field is deprecated in Consul 1.9.0. See the [`ui_config.dir`](#ui_config_dir) field instead.**
|
||||
Equivalent to the [`-ui-dir`](/docs/agent/config/agent-config-cli#_ui_dir) command-line
|
||||
Equivalent to the [`-ui-dir`](/docs/agent/config/cli-flags#_ui_dir) command-line
|
||||
flag. This configuration key is not required as of Consul version 0.7.0 and later.
|
||||
Specifying this configuration key will enable the web UI. There is no need to specify
|
||||
both ui-dir and ui. Specifying both will result in an error.
|
|
@ -16,8 +16,8 @@ descriptions.
|
|||
|
||||
Configuration precedence is evaluated in the following order:
|
||||
|
||||
1. [Command line arguments](/docs/agent/config/agent-config-cli)
|
||||
2. [Configuration files](/docs/agent/config/agent-config-files)
|
||||
1. [Command line arguments](/docs/agent/config/cli-flags)
|
||||
2. [Configuration files](/docs/agent/config/config-files)
|
||||
|
||||
When loading configuration, Consul loads the configuration from files and
|
||||
directories in lexical order. For example, configuration file
|
||||
|
@ -57,22 +57,22 @@ Reloading configuration does not reload all configuration items. The
|
|||
items which are reloaded include:
|
||||
|
||||
- ACL Tokens
|
||||
- [Configuration Entry Bootstrap](/docs/agent/config/agent-config-files#config_entries_bootstrap)
|
||||
- [Configuration Entry Bootstrap](/docs/agent/config/config-files#config_entries_bootstrap)
|
||||
- Checks
|
||||
- [Discard Check Output](/docs/agent/config/agent-config-files#discard_check_output)
|
||||
- [Discard Check Output](/docs/agent/config/config-files#discard_check_output)
|
||||
- HTTP Client Address
|
||||
- Log level
|
||||
- [Metric Prefix Filter](/docs/agent/config/agent-config-files#telemetry-prefix_filter)
|
||||
- [Node Metadata](/docs/agent/config/agent-config-files#node_meta)
|
||||
- [Metric Prefix Filter](/docs/agent/config/config-files#telemetry-prefix_filter)
|
||||
- [Node Metadata](/docs/agent/config/config-files#node_meta)
|
||||
- Some Raft options (since Consul 1.10.0)
|
||||
- [`raft_snapshot_threshold`](/docs/agent/config/agent-config-files#_raft_snapshot_threshold)
|
||||
- [`raft_snapshot_interval`](/docs/agent/config/agent-config-files#_raft_snapshot_interval)
|
||||
- [`raft_trailing_logs`](/docs/agent/config/agent-config-files#_raft_trailing_logs)
|
||||
- [`raft_snapshot_threshold`](/docs/agent/config/config-files#_raft_snapshot_threshold)
|
||||
- [`raft_snapshot_interval`](/docs/agent/config/config-files#_raft_snapshot_interval)
|
||||
- [`raft_trailing_logs`](/docs/agent/config/config-files#_raft_trailing_logs)
|
||||
- These can be important in certain outage situations so being able to control
|
||||
them without a restart provides a recovery path that doesn't involve
|
||||
downtime. They generally shouldn't be changed otherwise.
|
||||
- [RPC rate limiting](/docs/agent/config/agent-config-files#limits)
|
||||
- [HTTP Maximum Connections per Client](/docs/agent/config/agent-config-files#http_max_conns_per_client)
|
||||
- [RPC rate limiting](/docs/agent/config/config-files#limits)
|
||||
- [HTTP Maximum Connections per Client](/docs/agent/config/config-files#http_max_conns_per_client)
|
||||
- Services
|
||||
- TLS Configuration
|
||||
- Please be aware that this is currently limited to reload a configuration that is already TLS enabled. You cannot enable or disable TLS only with reloading.
|
||||
|
|
|
@ -127,16 +127,16 @@ $ consul agent -data-dir=/tmp/consul
|
|||
|
||||
- **Node name**: This is a unique name for the agent. By default, this
|
||||
is the hostname of the machine, but you may customize it using the
|
||||
[`-node`](/docs/agent/config/agent-config-cli#_node) flag.
|
||||
[`-node`](/docs/agent/config/cli-flags#_node) flag.
|
||||
|
||||
- **Datacenter**: This is the datacenter in which the agent is configured to
|
||||
run. For single-DC configurations, the agent will default to `dc1`, but you can configure which datacenter the agent reports to with the [`-datacenter`](/docs/agent/config/agent-config-cli#_datacenter) flag.
|
||||
run. For single-DC configurations, the agent will default to `dc1`, but you can configure which datacenter the agent reports to with the [`-datacenter`](/docs/agent/config/cli-flags#_datacenter) flag.
|
||||
Consul has first-class support for multiple datacenters, but configuring each node to report its datacenter improves agent efficiency.
|
||||
|
||||
- **Server**: This indicates whether the agent is running in server or client
|
||||
mode.
|
||||
Running an agent in server mode requires additional overhead. This is because they participate in the consensus quorum, store cluster state, and handle queries. A server may also be
|
||||
in ["bootstrap"](/docs/agent/config/agent-config-cli#_bootstrap_expect) mode, which enables the server to elect itselft as the Raft leader. Multiple servers cannot be in bootstrap mode because it would put the cluster in an inconsistent state.
|
||||
in ["bootstrap"](/docs/agent/config/cli-flags#_bootstrap_expect) mode, which enables the server to elect itselft as the Raft leader. Multiple servers cannot be in bootstrap mode because it would put the cluster in an inconsistent state.
|
||||
|
||||
- **Client Addr**: This is the address used for client interfaces to the agent.
|
||||
This includes the ports for the HTTP and DNS interfaces. By default, this
|
||||
|
@ -179,18 +179,18 @@ The following settings are commonly used in the configuration file (also called
|
|||
|
||||
| Parameter | Description | Default |
|
||||
| ------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- |
|
||||
| `node_name` | String value that specifies a name for the agent node. <br/>See [`-node-id`](/docs/agent/config/agent-config-cli#_node_id) for details. | Hostname of the machine |
|
||||
| `server` | Boolean value that determines if the agent runs in server mode. <br/>See [`-server`](/docs/agent/config/agent-config-cli#_server) for details. | `false` |
|
||||
| `datacenter` | String value that specifies which datacenter the agent runs in. <br/>See [-datacenter](/docs/agent/config/agent-config-cli#_datacenter) for details. | `dc1` |
|
||||
| `data_dir` | String value that specifies a directory for storing agent state data. <br/>See [`-data-dir`](/docs/agent/config/agent-config-cli#_data_dir) for details. | none |
|
||||
| `log_level` | String value that specifies the level of logging the agent reports. <br/>See [`-log-level`](/docs/agent/config/agent-config-cli#_log_level) for details. | `info` |
|
||||
| `retry_join` | Array of string values that specify one or more agent addresses to join after startup. The agent will continue trying to join the specified agents until it has successfully joined another member. <br/>See [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) for details. | none |
|
||||
| `addresses` | Block of nested objects that define addresses bound to the agent for internal cluster communication. | `"http": "0.0.0.0"` See the Agent Configuration page for [default address values](/docs/agent/config/agent-config-files#addresses) |
|
||||
| `ports` | Block of nested objects that define ports bound to agent addresses. <br/>See (link to addresses option) for details. | See the Agent Configuration page for [default port values](/docs/agent/config/agent-config-files#ports) |
|
||||
| `node_name` | String value that specifies a name for the agent node. <br/>See [`-node-id`](/docs/agent/config/cli-flags#_node_id) for details. | Hostname of the machine |
|
||||
| `server` | Boolean value that determines if the agent runs in server mode. <br/>See [`-server`](/docs/agent/config/cli-flags#_server) for details. | `false` |
|
||||
| `datacenter` | String value that specifies which datacenter the agent runs in. <br/>See [-datacenter](/docs/agent/config/cli-flags#_datacenter) for details. | `dc1` |
|
||||
| `data_dir` | String value that specifies a directory for storing agent state data. <br/>See [`-data-dir`](/docs/agent/config/cli-flags#_data_dir) for details. | none |
|
||||
| `log_level` | String value that specifies the level of logging the agent reports. <br/>See [`-log-level`](/docs/agent/config/cli-flags#_log_level) for details. | `info` |
|
||||
| `retry_join` | Array of string values that specify one or more agent addresses to join after startup. The agent will continue trying to join the specified agents until it has successfully joined another member. <br/>See [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) for details. | none |
|
||||
| `addresses` | Block of nested objects that define addresses bound to the agent for internal cluster communication. | `"http": "0.0.0.0"` See the Agent Configuration page for [default address values](/docs/agent/config/config-files#addresses) |
|
||||
| `ports` | Block of nested objects that define ports bound to agent addresses. <br/>See (link to addresses option) for details. | See the Agent Configuration page for [default port values](/docs/agent/config/config-files#ports) |
|
||||
|
||||
### Server Node in a Service Mesh
|
||||
|
||||
The following example configuration is for a server agent named "`consul-server`". The server is [bootstrapped](/docs/agent/config/agent-config-cli#_bootstrap) and the Consul GUI is enabled.
|
||||
The following example configuration is for a server agent named "`consul-server`". The server is [bootstrapped](/docs/agent/config/cli-flags#_bootstrap) and the Consul GUI is enabled.
|
||||
The reason this server agent is configured for a service mesh is that the `connect` configuration is enabled. Connect is Consul's service mesh component that provides service-to-service connection authorization and encryption using mutual Transport Layer Security (TLS). Applications can use sidecar proxies in a service mesh configuration to establish TLS connections for inbound and outbound connections without being aware of Connect at all. See [Connect](/docs/connect) for details.
|
||||
|
||||
<Tabs>
|
||||
|
@ -399,6 +399,6 @@ may not be important for your use case. For example, for a web server and load
|
|||
balancer setup, both result in the same outcome: the web node is removed
|
||||
from the load balancer pool.
|
||||
|
||||
The [`skip_leave_on_interrupt`](/docs/agent/config/agent-config-files#skip_leave_on_interrupt) and
|
||||
[`leave_on_terminate`](/docs/agent/config/agent-config-files#leave_on_terminate) configuration
|
||||
The [`skip_leave_on_interrupt`](/docs/agent/config/config-files#skip_leave_on_interrupt) and
|
||||
[`leave_on_terminate`](/docs/agent/config/config-files#leave_on_terminate) configuration
|
||||
options allow you to adjust this behavior.
|
||||
|
|
|
@ -29,7 +29,7 @@ This telemetry information can be used for debugging or otherwise
|
|||
getting a better view of what Consul is doing. Review the [Monitoring and
|
||||
Metrics tutorial](https://learn.hashicorp.com/tutorials/consul/monitor-datacenter-health?utm_source=consul.io&utm_medium=docs) to learn how collect and interpret Consul data.
|
||||
|
||||
Additionally, if the [`telemetry` configuration options](/docs/agent/config/agent-config-files#telemetry)
|
||||
Additionally, if the [`telemetry` configuration options](/docs/agent/config/config-files#telemetry)
|
||||
are provided, the telemetry information will be streamed to a
|
||||
[statsite](http://github.com/armon/statsite) or [statsd](http://github.com/etsy/statsd) server where
|
||||
it can be aggregated and flushed to Graphite or any other metrics store.
|
||||
|
@ -138,7 +138,7 @@ you will need to apply a function such as InfluxDB's [`non_negative_difference()
|
|||
| Metric Name | Description | Unit | Type |
|
||||
| :--------------------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :------- | :------ |
|
||||
| `consul.client.rpc` | Increments whenever a Consul agent in client mode makes an RPC request to a Consul server | requests | counter |
|
||||
| `consul.client.rpc.exceeded` | Increments whenever a Consul agent in client mode makes an RPC request to a Consul server gets rate limited by that agent's [`limits`](/docs/agent/config/agent-config-files#limits) configuration. | requests | counter |
|
||||
| `consul.client.rpc.exceeded` | Increments whenever a Consul agent in client mode makes an RPC request to a Consul server gets rate limited by that agent's [`limits`](/docs/agent/config/config-files#limits) configuration. | requests | counter |
|
||||
| `consul.client.rpc.failed` | Increments whenever a Consul agent in client mode makes an RPC request to a Consul server and fails. | requests | counter |
|
||||
|
||||
**Why they're important:** These measurements indicate the current load created from a Consul agent, including when the load becomes high enough to be rate limited. A high RPC count, especially from `consul.client.rpcexceeded` meaning that the requests are being rate-limited, could imply a misconfigured Consul agent.
|
||||
|
@ -170,7 +170,7 @@ Under these conditions, a follower after a restart may be unable to catch up on
|
|||
replication and become a voter again since it takes longer to restore from disk
|
||||
or the leader than the leader takes to write a new snapshot and truncate its
|
||||
logs. Servers retain
|
||||
[`raft_trailing_logs`](/docs/agent/config/agent-config-files#raft_trailing_logs) (default
|
||||
[`raft_trailing_logs`](/docs/agent/config/config-files#raft_trailing_logs) (default
|
||||
`10240`) log entries even if their snapshot was more recent. On a leader
|
||||
processing 500 commits/second, that is only about 20 seconds worth of logs.
|
||||
Assuming the leader is able to write out a snapshot and truncate the logs in
|
||||
|
@ -195,7 +195,7 @@ repeatedly as well as reduce the fault tolerance and serving capacity of the
|
|||
cluster.
|
||||
|
||||
Since Consul 1.5.3
|
||||
[`raft_trailing_logs`](/docs/agent/config/agent-config-files#raft_trailing_logs) has been
|
||||
[`raft_trailing_logs`](/docs/agent/config/config-files#raft_trailing_logs) has been
|
||||
configurable. Increasing it allows the leader to retain more logs and give
|
||||
followers more time to restore and catch up. The tradeoff is potentially
|
||||
slower appends which eventually might affect write throughput and latency
|
||||
|
@ -206,7 +206,7 @@ mean loosing cluster availability and needing to recover the cluster from a loss
|
|||
of quorum.
|
||||
|
||||
Since Consul 1.10.0
|
||||
[`raft_trailing_logs`](/docs/agent/config/agent-config-files#raft_trailing_logs) is now
|
||||
[`raft_trailing_logs`](/docs/agent/config/config-files#raft_trailing_logs) is now
|
||||
reloadable with `consul reload` or `SIGHUP` allowing operators to increase this
|
||||
without the leader restarting or loosing leadership allowing the cluster to be
|
||||
recovered gracefully.
|
||||
|
@ -277,7 +277,7 @@ This is a full list of metrics emitted by Consul.
|
|||
| `consul.acl.blocked.{check,node,service}.registration` | Increments whenever a registration fails for an entity (check, node or service) is blocked by an ACL. | requests | counter |
|
||||
| `consul.api.http` | Migrated from consul.http.. this samples how long it takes to service the given HTTP request for the given verb and path. Includes labels for `path` and `method`. `path` does not include details like service or key names, for these an underscore will be present as a placeholder (eg. path=`v1.kv._`) | ms | timer |
|
||||
| `consul.client.rpc` | Increments whenever a Consul agent in client mode makes an RPC request to a Consul server. This gives a measure of how much a given agent is loading the Consul servers. Currently, this is only generated by agents in client mode, not Consul servers. | requests | counter |
|
||||
| `consul.client.rpc.exceeded` | Increments whenever a Consul agent in client mode makes an RPC request to a Consul server gets rate limited by that agent's [`limits`](/docs/agent/config/agent-config-files#limits) configuration. This gives an indication that there's an abusive application making too many requests on the agent, or that the rate limit needs to be increased. Currently, this only applies to agents in client mode, not Consul servers. | rejected requests | counter |
|
||||
| `consul.client.rpc.exceeded` | Increments whenever a Consul agent in client mode makes an RPC request to a Consul server gets rate limited by that agent's [`limits`](/docs/agent/config/config-files#limits) configuration. This gives an indication that there's an abusive application making too many requests on the agent, or that the rate limit needs to be increased. Currently, this only applies to agents in client mode, not Consul servers. | rejected requests | counter |
|
||||
| `consul.client.rpc.failed` | Increments whenever a Consul agent in client mode makes an RPC request to a Consul server and fails. | requests | counter |
|
||||
| `consul.client.api.catalog_register.` | Increments whenever a Consul agent receives a catalog register request. | requests | counter |
|
||||
| `consul.client.api.success.catalog_register.` | Increments whenever a Consul agent successfully responds to a catalog register request. | requests | counter |
|
||||
|
@ -375,7 +375,7 @@ These metrics are used to monitor the health of the Consul servers.
|
|||
| `consul.raft.last_index` | Represents the raft applied index. | index | gauge |
|
||||
| `consul.raft.leader.dispatchLog` | Measures the time it takes for the leader to write log entries to disk. | ms | timer |
|
||||
| `consul.raft.leader.dispatchNumLogs` | Measures the number of logs committed to disk in a batch. | logs | gauge |
|
||||
| `consul.raft.leader.lastContact` | Measures the time since the leader was last able to contact the follower nodes when checking its leader lease. It can be used as a measure for how stable the Raft timing is and how close the leader is to timing out its lease.The lease timeout is 500 ms times the [`raft_multiplier` configuration](/docs/agent/config/agent-config-files#raft_multiplier), so this telemetry value should not be getting close to that configured value, otherwise the Raft timing is marginal and might need to be tuned, or more powerful servers might be needed. See the [Server Performance](/docs/install/performance) guide for more details. | ms | timer |
|
||||
| `consul.raft.leader.lastContact` | Measures the time since the leader was last able to contact the follower nodes when checking its leader lease. It can be used as a measure for how stable the Raft timing is and how close the leader is to timing out its lease.The lease timeout is 500 ms times the [`raft_multiplier` configuration](/docs/agent/config/config-files#raft_multiplier), so this telemetry value should not be getting close to that configured value, otherwise the Raft timing is marginal and might need to be tuned, or more powerful servers might be needed. See the [Server Performance](/docs/install/performance) guide for more details. | ms | timer |
|
||||
| `consul.raft.leader.oldestLogAge` | The number of milliseconds since the _oldest_ log in the leader's log store was written. This can be important for replication health where write rate is high and the snapshot is large as followers may be unable to recover from a restart if restoring takes longer than the minimum value for the current leader. Compare this with `consul.raft.fsm.lastRestoreDuration` and `consul.raft.rpc.installSnapshot` to monitor. In normal usage this gauge value will grow linearly over time until a snapshot completes on the leader and the log is truncated. Note: this metric won't be emitted until the leader writes a snapshot. After an upgrade to Consul 1.10.0 it won't be emitted until the oldest log was written after the upgrade. | ms | gauge |
|
||||
| `consul.raft.replication.heartbeat` | Measures the time taken to invoke appendEntries on a peer, so that it doesn’t timeout on a periodic basis. | ms | timer |
|
||||
| `consul.raft.replication.appendEntries` | Measures the time it takes to replicate log entries to followers. This is a general indicator of the load pressure on the Consul servers, as well as the performance of the communication between the servers. | ms | timer |
|
||||
|
@ -473,7 +473,7 @@ These metrics give insight into the health of the cluster as a whole.
|
|||
| `consul.memberlist.degraded.timeout` | Counts the number of times an agent was marked as a dead node, whilst not getting enough confirmations from a randomly selected list of agent nodes in an agent's membership. | occurrence / interval | counter |
|
||||
| `consul.memberlist.msg.dead` | Counts the number of times an agent has marked another agent to be a dead node. | messages / interval | counter |
|
||||
| `consul.memberlist.health.score` | Describes a node's perception of its own health based on how well it is meeting the soft real-time requirements of the protocol. This metric ranges from 0 to 8, where 0 indicates "totally healthy". This health score is used to scale the time between outgoing probes, and higher scores translate into longer probing intervals. For more details see section IV of the Lifeguard paper: https://arxiv.org/pdf/1707.00788.pdf | score | gauge |
|
||||
| `consul.memberlist.msg.suspect` | Increments when an agent suspects another as failed when executing random probes as part of the gossip protocol. These can be an indicator of overloaded agents, network problems, or configuration errors where agents can not connect to each other on the [required ports](/docs/agent/config/agent-config-files#ports). | suspect messages received / interval | counter |
|
||||
| `consul.memberlist.msg.suspect` | Increments when an agent suspects another as failed when executing random probes as part of the gossip protocol. These can be an indicator of overloaded agents, network problems, or configuration errors where agents can not connect to each other on the [required ports](/docs/agent/config/config-files#ports). | suspect messages received / interval | counter |
|
||||
| `consul.memberlist.tcp.accept` | Counts the number of times an agent has accepted an incoming TCP stream connection. | connections accepted / interval | counter |
|
||||
| `consul.memberlist.udp.sent/received` | Measures the total number of bytes sent/received by an agent through the UDP protocol. | bytes sent or bytes received / interval | counter |
|
||||
| `consul.memberlist.tcp.connect` | Counts the number of times an agent has initiated a push/pull sync with an other agent. | push/pull initiated / interval | counter |
|
||||
|
@ -484,8 +484,8 @@ These metrics give insight into the health of the cluster as a whole.
|
|||
| `consul.memberlist.msg_suspect` | The number of suspect messages that the agent has processed so far, based on the message information given by the network layer. | messages / Interval | counter |
|
||||
| `consul.memberlist.probeNode` | Measures the time taken to perform a single round of failure detection on a select agent. | nodes / Interval | counter |
|
||||
| `consul.memberlist.pushPullNode` | Measures the number of agents that have exchanged state with this agent. | nodes / Interval | counter |
|
||||
| `consul.serf.member.failed` | Increments when an agent is marked dead. This can be an indicator of overloaded agents, network problems, or configuration errors where agents cannot connect to each other on the [required ports](/docs/agent/config/agent-config-files#ports). | failures / interval | counter |
|
||||
| `consul.serf.member.flap` | Available in Consul 0.7 and later, this increments when an agent is marked dead and then recovers within a short time period. This can be an indicator of overloaded agents, network problems, or configuration errors where agents cannot connect to each other on the [required ports](/docs/agent/config/agent-config-files#ports). | flaps / interval | counter |
|
||||
| `consul.serf.member.failed` | Increments when an agent is marked dead. This can be an indicator of overloaded agents, network problems, or configuration errors where agents cannot connect to each other on the [required ports](/docs/agent/config/config-files#ports). | failures / interval | counter |
|
||||
| `consul.serf.member.flap` | Available in Consul 0.7 and later, this increments when an agent is marked dead and then recovers within a short time period. This can be an indicator of overloaded agents, network problems, or configuration errors where agents cannot connect to each other on the [required ports](/docs/agent/config/config-files#ports). | flaps / interval | counter |
|
||||
| `consul.serf.member.join` | Increments when an agent joins the cluster. If an agent flapped or failed this counter also increments when it re-joins. | joins / interval | counter |
|
||||
| `consul.serf.member.left` | Increments when an agent leaves the cluster. | leaves / interval | counter |
|
||||
| `consul.serf.events` | Increments when an agent processes an [event](/commands/event). Consul uses events internally so there may be additional events showing in telemetry. There are also a per-event counters emitted as `consul.serf.events.`. | events / interval | counter |
|
||||
|
|
|
@ -173,11 +173,11 @@ So monthly cost would be calculated as:
|
|||
- 500 ⨉ 13.3 = 6,650 certificates issued in dc3
|
||||
|
||||
The number of certificates issued could be reduced by increasing
|
||||
[`leaf_cert_ttl`](/docs/agent/config/agent-config-files#ca_leaf_cert_ttl) in the CA Provider
|
||||
[`leaf_cert_ttl`](/docs/agent/config/config-files#ca_leaf_cert_ttl) in the CA Provider
|
||||
configuration if the longer lived credentials are an acceptable risk tradeoff
|
||||
against the cost.
|
||||
|
||||
<!-- Reference style links -->
|
||||
[`ca_config`]: /docs/agent/config/agent-config-files#connect_ca_config
|
||||
[`ca_provider`]: /docs/agent/config/agent-config-files#connect_ca_provider
|
||||
[`ca_config`]: /docs/agent/config/config-files#connect_ca_config
|
||||
[`ca_provider`]: /docs/agent/config/config-files#connect_ca_provider
|
||||
[`/connect/ca/configuration`]: /api-docs/connect/ca#update-ca-configuration
|
||||
|
|
|
@ -92,7 +92,7 @@ Connect is enabled - the PrivateKey and RootCert fields have not been set, so th
|
|||
been generated (as seen above in the roots list).
|
||||
|
||||
There are two ways to have the Consul CA use a custom private key and root certificate:
|
||||
either through the `ca_config` section of the [Agent configuration](/docs/agent/config/agent-config-files#connect_ca_config) (which can only be used during the cluster's
|
||||
either through the `ca_config` section of the [Agent configuration](/docs/agent/config/config-files#connect_ca_config) (which can only be used during the cluster's
|
||||
initial bootstrap) or through the [Update CA Configuration endpoint](/api/connect/ca#update-ca-configuration).
|
||||
|
||||
Currently Consul requires that root certificates are valid [SPIFFE SVID Signing certificates](https://github.com/spiffe/spiffe/blob/master/standards/X509-SVID.md) and that the URI encoded
|
||||
|
|
|
@ -30,7 +30,7 @@ will generate the initial root certificates and setup the internal Consul server
|
|||
state.
|
||||
|
||||
For the initial bootstrap, the CA provider can be configured through the
|
||||
[Agent configuration](/docs/agent/config/agent-config-files#connect_ca_config). After
|
||||
[Agent configuration](/docs/agent/config/config-files#connect_ca_config). After
|
||||
initialization, the CA can only be updated through the
|
||||
[Update CA Configuration API endpoint](/api/connect/ca#update-ca-configuration).
|
||||
If a CA is already initialized, any changes to the CA configuration in the
|
||||
|
|
|
@ -271,6 +271,6 @@ path "/connect_inter/*" {
|
|||
</CodeBlockConfig>
|
||||
|
||||
<!-- Reference style links -->
|
||||
[`ca_config`]: /docs/agent/config/agent-config-files#connect_ca_config
|
||||
[`ca_provider`]: /docs/agent/config/agent-config-files#connect_ca_provider
|
||||
[`ca_config`]: /docs/agent/config/config-files#connect_ca_config
|
||||
[`ca_provider`]: /docs/agent/config/config-files#connect_ca_provider
|
||||
[`/connect/ca/configuration`]: /api-docs/connect/ca#update-ca-configuration
|
||||
|
|
|
@ -28,7 +28,7 @@ You can configure the settings defined in the `exported-services` configuration
|
|||
## Usage
|
||||
|
||||
1. Verify that your datacenter meets the conditions specified in the [Requirements](#requirements).
|
||||
1. Specify the `exported-services` configuration in the agent configuration file (see [`config_entries`](/docs/agent/config/agent-config-files#config_entries)) as described in [Configuration](#configuration).
|
||||
1. Specify the `exported-services` configuration in the agent configuration file (see [`config_entries`](/docs/agent/config/config-files#config_entries)) as described in [Configuration](#configuration).
|
||||
1. Apply the configuration using one of the following methods:
|
||||
- Kubernetes CRD: Refer to the [Custom Resource Definitions](/docs/k8s/crds) documentation for details.
|
||||
- Issue the `consul config write` command: Refer to the [Consul Config Write](/commands/config/write) documentation for details.
|
||||
|
|
|
@ -49,7 +49,7 @@ See [Agent - Config Entries](/docs/agent/config-entries).
|
|||
## Using Configuration Entries For Service Defaults
|
||||
|
||||
Outside of Kubernetes, when the agent is
|
||||
[configured](/docs/agent/config/agent-config-files#enable_central_service_config) to enable
|
||||
[configured](/docs/agent/config/config-files#enable_central_service_config) to enable
|
||||
central service configurations, it will look for service configuration defaults
|
||||
that match a registering service instance. If it finds any, the agent will merge
|
||||
those defaults with the service instance configuration. This allows for things
|
||||
|
|
|
@ -300,8 +300,8 @@ spec:
|
|||
type: 'bool: false',
|
||||
description: `If enabled, all HTTP and gRPC checks registered with the agent are exposed through Envoy.
|
||||
Envoy will expose listeners for these checks and will only accept connections originating from localhost or Consul's
|
||||
[advertise address](/docs/agent/config/agent-config-files#advertise). The port for these listeners are dynamically allocated from
|
||||
[expose_min_port](/docs/agent/config/agent-config-files#expose_min_port) to [expose_max_port](/docs/agent/config/agent-config-files#expose_max_port).
|
||||
[advertise address](/docs/agent/config/config-files#advertise). The port for these listeners are dynamically allocated from
|
||||
[expose_min_port](/docs/agent/config/config-files#expose_min_port) to [expose_max_port](/docs/agent/config/config-files#expose_max_port).
|
||||
This flag is useful when a Consul client cannot reach registered services over localhost.`,
|
||||
},
|
||||
{
|
||||
|
|
|
@ -649,8 +649,8 @@ spec:
|
|||
type: 'bool: false',
|
||||
description: `If enabled, all HTTP and gRPC checks registered with the agent are exposed through Envoy.
|
||||
Envoy will expose listeners for these checks and will only accept connections originating from localhost or Consul's
|
||||
[advertise address](/docs/agent/config/agent-config-files#advertise). The port for these listeners are dynamically allocated from
|
||||
[expose_min_port](/docs/agent/config/agent-config-files#expose_min_port) to [expose_max_port](/docs/agent/config/agent-config-files#expose_max_port).
|
||||
[advertise address](/docs/agent/config/config-files#advertise). The port for these listeners are dynamically allocated from
|
||||
[expose_min_port](/docs/agent/config/config-files#expose_min_port) to [expose_max_port](/docs/agent/config/config-files#expose_max_port).
|
||||
This flag is useful when a Consul client cannot reach registered services over localhost. One example is when running
|
||||
Consul on Kubernetes, and Consul agents run in their own pods.`,
|
||||
},
|
||||
|
|
|
@ -468,7 +468,7 @@ spec:
|
|||
first permission to match in the list is terminal and stops further
|
||||
evaluation. As with L4 intentions, traffic that fails to match any of the
|
||||
provided permissions in this intention will be subject to the default
|
||||
intention behavior is defined by the default [ACL policy](/docs/agent/config/agent-config-files#acl_default_policy).<br><br>
|
||||
intention behavior is defined by the default [ACL policy](/docs/agent/config/config-files#acl_default_policy).<br><br>
|
||||
This should be omitted for an L4 intention as it is mutually exclusive with
|
||||
the \`Action\` field.<br><br>
|
||||
Setting \`Permissions\` is not valid if a wildcard is used for the \`Name\` or \`Namespace\` because they can only be
|
||||
|
@ -478,7 +478,7 @@ spec:
|
|||
first permission to match in the list is terminal and stops further
|
||||
evaluation. As with L4 intentions, traffic that fails to match any of the
|
||||
provided permissions in this intention will be subject to the default
|
||||
intention behavior is defined by the default [ACL policy](/docs/agent/config/agent-config-files#acl_default_policy).<br><br>
|
||||
intention behavior is defined by the default [ACL policy](/docs/agent/config/config-files#acl_default_policy).<br><br>
|
||||
This should be omitted for an L4 intention as it is mutually exclusive with
|
||||
the \`action\` field.<br><br>
|
||||
Setting \`permissions\` is not valid if a wildcard is used for the \`spec.destination.name\` or \`spec.destination.namespace\`
|
||||
|
|
|
@ -22,7 +22,7 @@ The first step to use Connect is to enable Connect for your Consul
|
|||
cluster. By default, Connect is disabled. Enabling Connect requires changing
|
||||
the configuration of only your Consul _servers_ (not client agents). To enable
|
||||
Connect, add the following to a new or existing
|
||||
[server configuration file](/docs/agent/config/agent-config-files). In an existing cluster, this configuration change requires a Consul server restart, which you can perform one server at a time to maintain availability. In HCL:
|
||||
[server configuration file](/docs/agent/config/config-files). In an existing cluster, this configuration change requires a Consul server restart, which you can perform one server at a time to maintain availability. In HCL:
|
||||
|
||||
```hcl
|
||||
connect {
|
||||
|
@ -43,20 +43,20 @@ connection attempts to fail until Connect is enabled on the server agents.
|
|||
Other optional Connect configurations that you can set in the server
|
||||
configuration file include:
|
||||
|
||||
- [certificate authority settings](/docs/agent/config/agent-config-files#connect)
|
||||
- [token replication](/docs/agent/config/agent-config-files#acl_tokens_replication)
|
||||
- [dev mode](/docs/agent/config/agent-config-cli#_dev)
|
||||
- [server host name verification](/docs/agent/config/agent-config-files#verify_server_hostname)
|
||||
- [certificate authority settings](/docs/agent/config/config-files#connect)
|
||||
- [token replication](/docs/agent/config/config-files#acl_tokens_replication)
|
||||
- [dev mode](/docs/agent/config/cli-flags#_dev)
|
||||
- [server host name verification](/docs/agent/config/config-files#verify_server_hostname)
|
||||
|
||||
If you would like to use Envoy as your Connect proxy you will need to [enable
|
||||
gRPC](/docs/agent/config/agent-config-files#grpc_port).
|
||||
gRPC](/docs/agent/config/config-files#grpc_port).
|
||||
|
||||
Additionally if you plan on using the observability features of Connect, it can
|
||||
be convenient to configure your proxies and services using [configuration
|
||||
entries](/docs/agent/config-entries) which you can interact with using the
|
||||
CLI or API, or by creating configuration entry files. You will want to enable
|
||||
[centralized service
|
||||
configuration](/docs/agent/config/agent-config-files#enable_central_service_config) on
|
||||
configuration](/docs/agent/config/config-files#enable_central_service_config) on
|
||||
clients, which allows each service's proxy configuration to be managed centrally
|
||||
via API.
|
||||
|
||||
|
|
|
@ -109,10 +109,10 @@ externally routable IPs at the service level.
|
|||
## Intention Replication
|
||||
|
||||
Intention replication happens automatically but requires the
|
||||
[`primary_datacenter`](/docs/agent/config/agent-config-files#primary_datacenter)
|
||||
[`primary_datacenter`](/docs/agent/config/config-files#primary_datacenter)
|
||||
configuration to be set to specify a datacenter that is authoritative
|
||||
for intentions. In production setups with ACLs enabled, the
|
||||
[replication token](/docs/agent/config/agent-config-files#acl_tokens_replication) must also
|
||||
[replication token](/docs/agent/config/config-files#acl_tokens_replication) must also
|
||||
be set in the secondary datacenter server's configuration.
|
||||
|
||||
## Certificate Authority Federation
|
||||
|
|
|
@ -40,8 +40,8 @@ the [hosts](/docs/connect/config-entries/ingress-gateway#hosts) field.
|
|||
Ingress gateways also require that your Consul datacenters are configured correctly:
|
||||
|
||||
- You'll need to use Consul version 1.8.0 or newer.
|
||||
- Consul [Connect](/docs/agent/config/agent-config-files#connect) must be enabled on the datacenter's Consul servers.
|
||||
- [gRPC](/docs/agent/config/agent-config-files#grpc_port) must be enabled on all client agents.
|
||||
- Consul [Connect](/docs/agent/config/config-files#connect) must be enabled on the datacenter's Consul servers.
|
||||
- [gRPC](/docs/agent/config/config-files#grpc_port) must be enabled on all client agents.
|
||||
|
||||
Currently, [Envoy](https://www.envoyproxy.io/) is the only proxy with ingress gateway capabilities in Consul.
|
||||
|
||||
|
|
|
@ -30,12 +30,12 @@ Ensure that your Consul environment meets the following requirements.
|
|||
|
||||
* Consul version 1.6.0 or newer.
|
||||
* A local Consul agent is required to manage its configuration.
|
||||
* Consul [Connect](/docs/agent/config/agent-config-files#connect) must be enabled in both datacenters.
|
||||
* Each [datacenter](/docs/agent/config/agent-config-files#datacenter) must have a unique name.
|
||||
* Consul [Connect](/docs/agent/config/config-files#connect) must be enabled in both datacenters.
|
||||
* Each [datacenter](/docs/agent/config/config-files#datacenter) must have a unique name.
|
||||
* Each datacenters must be [WAN joined](https://learn.hashicorp.com/tutorials/consul/federarion-gossip-wan).
|
||||
* The [primary datacenter](/docs/agent/config/agent-config-files#primary_datacenter) must be set to the same value in both datacenters. This specifies which datacenter is the authority for Connect certificates and is required for services in all datacenters to establish mutual TLS with each other.
|
||||
* [gRPC](/docs/agent/config/agent-config-files#grpc_port) must be enabled.
|
||||
* If you want to [enable gateways globally](/docs/connect/mesh-gateway#enabling-gateways-globally) you must enable [centralized configuration](/docs/agent/config/agent-config-files#enable_central_service_config).
|
||||
* The [primary datacenter](/docs/agent/config/config-files#primary_datacenter) must be set to the same value in both datacenters. This specifies which datacenter is the authority for Connect certificates and is required for services in all datacenters to establish mutual TLS with each other.
|
||||
* [gRPC](/docs/agent/config/config-files#grpc_port) must be enabled.
|
||||
* If you want to [enable gateways globally](/docs/connect/mesh-gateway#enabling-gateways-globally) you must enable [centralized configuration](/docs/agent/config/config-files#enable_central_service_config).
|
||||
|
||||
### Network
|
||||
|
||||
|
|
|
@ -24,9 +24,9 @@ Ensure that your Consul environment meets the following requirements.
|
|||
|
||||
* Consul Enterprise version 1.11.0 or newer.
|
||||
* A local Consul agent is required to manage its configuration.
|
||||
* Consul service mesh must be enabled in all partitions. Refer to the [`connect` documentation](/docs/agent/config/agent-config-files#connect) for details.
|
||||
* Consul service mesh must be enabled in all partitions. Refer to the [`connect` documentation](/docs/agent/config/config-files#connect) for details.
|
||||
* Each partition must have a unique name. Refer to the [admin partitions documentation](/docs/enteprise/admin-partitions) for details.
|
||||
* If you want to [enable gateways globally](/docs/connect/mesh-gateway#enabling-gateways-globally) you must enable [centralized configuration](/docs/agent/config/agent-config-files#enable_central_service_config).
|
||||
* If you want to [enable gateways globally](/docs/connect/mesh-gateway#enabling-gateways-globally) you must enable [centralized configuration](/docs/agent/config/config-files#enable_central_service_config).
|
||||
|
||||
### Proxy
|
||||
|
||||
|
|
|
@ -124,7 +124,7 @@ connect {
|
|||
}
|
||||
```
|
||||
|
||||
Any references to [`start_join_wan`](/docs/agent/config/agent-config-files#start_join_wan) or [`retry_join_wan`](/docs/agent/config/agent-config-files#retry_join_wan) should be omitted.
|
||||
Any references to [`start_join_wan`](/docs/agent/config/config-files#start_join_wan) or [`retry_join_wan`](/docs/agent/config/config-files#retry_join_wan) should be omitted.
|
||||
|
||||
-> The `primary_gateways` configuration can also use `go-discover` syntax just
|
||||
like `retry_join_wan`.
|
||||
|
|
|
@ -59,8 +59,8 @@ Each terminating gateway needs:
|
|||
Terminating gateways also require that your Consul datacenters are configured correctly:
|
||||
|
||||
- You'll need to use Consul version 1.8.0 or newer.
|
||||
- Consul [Connect](/docs/agent/config/agent-config-files#connect) must be enabled on the datacenter's Consul servers.
|
||||
- [gRPC](/docs/agent/config/agent-config-files#grpc_port) must be enabled on all client agents.
|
||||
- Consul [Connect](/docs/agent/config/config-files#connect) must be enabled on the datacenter's Consul servers.
|
||||
- [gRPC](/docs/agent/config/config-files#grpc_port) must be enabled on all client agents.
|
||||
|
||||
Currently, [Envoy](https://www.envoyproxy.io/) is the only proxy with terminating gateway capabilities in Consul.
|
||||
|
||||
|
|
|
@ -25,7 +25,7 @@ is allowed by testing the intentions. If authorize returns false the
|
|||
connection must be terminated.
|
||||
|
||||
The default intention behavior is defined by the default [ACL
|
||||
policy](/docs/agent/config/agent-config-files#acl_default_policy). If the default ACL policy is
|
||||
policy](/docs/agent/config/config-files#acl_default_policy). If the default ACL policy is
|
||||
"allow all", then all Connect connections are allowed by default. If the
|
||||
default ACL policy is "deny all", then all Connect connections are denied by
|
||||
default.
|
||||
|
|
|
@ -49,7 +49,7 @@ target destination. After verifying the TLS client certificate, the cached
|
|||
intentions should be consulted for each incoming connection/request to
|
||||
determine if it should be accepted or rejected.
|
||||
|
||||
The default intention behavior is defined by the [`default_policy`](/docs/agent/config/agent-config-files#acl_default_policy) configuration.
|
||||
The default intention behavior is defined by the [`default_policy`](/docs/agent/config/config-files#acl_default_policy) configuration.
|
||||
If the configuration is set `allow`, then all service mesh Connect connections will be allowed by default.
|
||||
If is set to `deny`, then all connections or requests will be denied by default.
|
||||
|
||||
|
|
|
@ -18,10 +18,10 @@ to:
|
|||
- Define the upstreams for each of your services.
|
||||
|
||||
If you are using Envoy as your sidecar proxy, you will need to [enable
|
||||
gRPC](/docs/agent/config/agent-config-files#grpc_port) on your client agents. To define the
|
||||
gRPC](/docs/agent/config/config-files#grpc_port) on your client agents. To define the
|
||||
metrics destination and service protocol you may want to enable [configuration
|
||||
entries](/docs/agent/config/agent-config-files#config_entries) and [centralized service
|
||||
configuration](/docs/agent/config/agent-config-files#enable_central_service_config).
|
||||
entries](/docs/agent/config/config-files#config_entries) and [centralized service
|
||||
configuration](/docs/agent/config/config-files#enable_central_service_config).
|
||||
|
||||
### Kubernetes
|
||||
If you are using Kubernetes, the Helm chart can simplify much of the configuration needed to enable observability. See
|
||||
|
|
|
@ -47,11 +47,11 @@ UI. If there are multiple clients with the UI enabled in a datacenter for
|
|||
redundancy these configurations must be added to all of them.
|
||||
|
||||
We assume that the UI is already enabled by setting
|
||||
[`ui_config.enabled`](/docs/agent/config/agent-config-files#ui_config_enabled) to `true` in the
|
||||
[`ui_config.enabled`](/docs/agent/config/config-files#ui_config_enabled) to `true` in the
|
||||
agent's configuration file.
|
||||
|
||||
To use the built-in Prometheus provider
|
||||
[`ui_config.metrics_provider`](/docs/agent/config/agent-config-files#ui_config_metrics_provider)
|
||||
[`ui_config.metrics_provider`](/docs/agent/config/config-files#ui_config_metrics_provider)
|
||||
must be set to `prometheus`.
|
||||
|
||||
The UI must query the metrics provider through a proxy endpoint. This simplifies
|
||||
|
@ -59,7 +59,7 @@ deployment where Prometheus is not exposed externally to UI user's browsers.
|
|||
|
||||
To set this up, provide the URL that the _Consul agent_ should use to reach the
|
||||
Prometheus server in
|
||||
[`ui_config.metrics_proxy.base_url`](/docs/agent/config/agent-config-files#ui_config_metrics_proxy_base_url).
|
||||
[`ui_config.metrics_proxy.base_url`](/docs/agent/config/config-files#ui_config_metrics_proxy_base_url).
|
||||
For example in Kubernetes, the Prometheus helm chart by default installs a
|
||||
service named `prometheus-server` so each Consul agent can reach it on
|
||||
`http://prometheus-server` (using Kubernetes' DNS resolution).
|
||||
|
@ -87,7 +87,7 @@ service-specific dashboard in an external tool like
|
|||
[Grafana](https://grafana.com) or a hosted provider.
|
||||
|
||||
To configure this, you must provide a URL template in the [agent configuration
|
||||
file](/docs/agent/config/agent-config-files#ui_config_dashboard_url_templates) for all agents that
|
||||
file](/docs/agent/config/config-files#ui_config_dashboard_url_templates) for all agents that
|
||||
have the UI enabled. The template is essentially the URL to the external
|
||||
dashboard, but can have placeholder values which will be replaced with the
|
||||
service name, namespace and datacenter where appropriate to allow deep-linking
|
||||
|
@ -498,12 +498,12 @@ ui_config {
|
|||
```
|
||||
|
||||
More than one JavaScript file may be specified in
|
||||
[`metrics_provider_files`](/docs/agent/config/agent-config-files#ui_config_metrics_provider_files)
|
||||
[`metrics_provider_files`](/docs/agent/config/config-files#ui_config_metrics_provider_files)
|
||||
and all we be served allowing flexibility if needed to include dependencies.
|
||||
Only one metrics provider can be configured and used at one time.
|
||||
|
||||
The
|
||||
[`metrics_provider_options_json`](/docs/agent/config/agent-config-files#ui_config_metrics_provider_options_json)
|
||||
[`metrics_provider_options_json`](/docs/agent/config/config-files#ui_config_metrics_provider_options_json)
|
||||
field is an optional literal JSON object which is passed to the provider's
|
||||
`init` method at startup time. This allows configuring arbitrary parameters for
|
||||
the provider in config rather than hard coding them into the provider itself to
|
||||
|
@ -512,7 +512,7 @@ make providers more reusable.
|
|||
The provider may fetch metrics directly from another source although in this
|
||||
case the agent will probably need to serve the correct CORS headers to prevent
|
||||
browsers from blocking these requests. These may be configured with
|
||||
[`http_config.response_headers`](/docs/agent/config/agent-config-files#response_headers).
|
||||
[`http_config.response_headers`](/docs/agent/config/config-files#response_headers).
|
||||
|
||||
Alternatively, the provider may choose to use the [built-in metrics
|
||||
proxy](#metrics-proxy) to avoid cross domain issues or to inject additional
|
||||
|
|
|
@ -58,7 +58,7 @@ All fields are optional with a reasonable default.
|
|||
|
||||
- `bind_port` - The port the proxy will bind its _public_
|
||||
mTLS listener to. If not provided, the agent will attempt to assign one from its
|
||||
[configured proxy port range](/docs/agent/config/agent-config-files#sidecar_min_port) if available.
|
||||
[configured proxy port range](/docs/agent/config/config-files#sidecar_min_port) if available.
|
||||
By default the range is [20000, 20255] and the port is selected at random from
|
||||
that range.
|
||||
|
||||
|
|
|
@ -188,7 +188,7 @@ the upstream listeners of any downstream service.
|
|||
|
||||
One example is how users can define a service's protocol in a [`service-defaults` configuration
|
||||
entry](/docs/connect/config-entries/service-defaults). Agents with
|
||||
[`enable_central_service_config`](/docs/agent/config/agent-config-files#enable_central_service_config)
|
||||
[`enable_central_service_config`](/docs/agent/config/config-files#enable_central_service_config)
|
||||
set to true will automatically discover the protocol when configuring a proxy
|
||||
for a service. The proxy will discover the main protocol of the service it
|
||||
represents and use this to configure its main public listener. It will also
|
||||
|
|
|
@ -24,7 +24,7 @@ Managed proxies have been deprecated since Consul 1.3 and have been fully remove
|
|||
in Consul 1.6. Anyone using Managed Proxies should aim to change their workflow
|
||||
as soon as possible to avoid issues with a later upgrade.
|
||||
|
||||
After transitioning away from all managed proxy usage, the `proxy` subdirectory inside [`data_dir`](/docs/agent/config/agent-config-cli#_data_dir) (specified in Consul config) can be deleted to remove extraneous configuration files and free up disk space.
|
||||
After transitioning away from all managed proxy usage, the `proxy` subdirectory inside [`data_dir`](/docs/agent/config/cli-flags#_data_dir) (specified in Consul config) can be deleted to remove extraneous configuration files and free up disk space.
|
||||
|
||||
**new and known issues will not be fixed**.
|
||||
|
||||
|
@ -275,6 +275,6 @@ level logs showing service discovery, certificate and authorization information.
|
|||
|
||||
~> **Note:** In `-dev` mode there is no `data_dir` unless one is explicitly
|
||||
configured so logging is disabled. You can access logs by providing the
|
||||
[`-data-dir`](/docs/agent/config/agent-config-cli#_data_dir) CLI option. If a data dir is
|
||||
[`-data-dir`](/docs/agent/config/cli-flags#_data_dir) CLI option. If a data dir is
|
||||
configured, this will also cause proxy processes to stay running when the agent
|
||||
terminates as described in [Lifecycle](#lifecycle).
|
||||
|
|
|
@ -437,8 +437,8 @@ registrations](/docs/agent/services#service-definition-parameter-case).
|
|||
|
||||
- `checks` `(bool: false)` - If enabled, all HTTP and gRPC checks registered with the agent are exposed through Envoy.
|
||||
Envoy will expose listeners for these checks and will only accept connections originating from localhost or Consul's
|
||||
[advertise address](/docs/agent/config/agent-config-files#advertise). The port for these listeners are dynamically allocated from
|
||||
[expose_min_port](/docs/agent/config/agent-config-files#expose_min_port) to [expose_max_port](/docs/agent/config/agent-config-files#expose_max_port).
|
||||
[advertise address](/docs/agent/config/config-files#advertise). The port for these listeners are dynamically allocated from
|
||||
[expose_min_port](/docs/agent/config/config-files#expose_min_port) to [expose_max_port](/docs/agent/config/config-files#expose_max_port).
|
||||
This flag is useful when a Consul client cannot reach registered services over localhost. One example is when running
|
||||
Consul on Kubernetes, and Consul agents run in their own pods.
|
||||
- `paths` `array<Path>: []` - A list of paths to expose through Envoy.
|
||||
|
|
|
@ -131,7 +131,7 @@ proxy.
|
|||
- `tags` - Defaults to the tags of the parent service.
|
||||
- `meta` - Defaults to the service metadata of the parent service.
|
||||
- `port` - Defaults to being auto-assigned from a [configurable
|
||||
range](/docs/agent/config/agent-config-files#sidecar_min_port) that is
|
||||
range](/docs/agent/config/config-files#sidecar_min_port) that is
|
||||
by default `[21000, 21255]`.
|
||||
- `kind` - Defaults to `connect-proxy`. This can't be overridden currently.
|
||||
- `check`, `checks` - By default we add a TCP check on the local address and
|
||||
|
|
|
@ -34,10 +34,10 @@ There are several different kinds of checks:
|
|||
In Consul 0.9.0 and later, script checks are not enabled by default. To use them you
|
||||
can either use :
|
||||
|
||||
- [`enable_local_script_checks`](/docs/agent/config/agent-config-cli#_enable_local_script_checks):
|
||||
- [`enable_local_script_checks`](/docs/agent/config/cli-flags#_enable_local_script_checks):
|
||||
enable script checks defined in local config files. Script checks defined via the HTTP
|
||||
API will not be allowed.
|
||||
- [`enable_script_checks`](/docs/agent/config/agent-config-cli#_enable_script_checks): enable
|
||||
- [`enable_script_checks`](/docs/agent/config/cli-flags#_enable_script_checks): enable
|
||||
script checks regardless of how they are defined.
|
||||
|
||||
~> **Security Warning:** Enabling script checks in some configurations may
|
||||
|
@ -105,7 +105,7 @@ There are several different kinds of checks:
|
|||
has to be performed is configurable which makes it possible to run containers which
|
||||
have different shells on the same host. Check output for Docker is limited to
|
||||
4KB. Any output larger than this will be truncated. In Consul 0.9.0 and later, the agent
|
||||
must be configured with [`enable_script_checks`](/docs/agent/config/agent-config-cli#_enable_script_checks)
|
||||
must be configured with [`enable_script_checks`](/docs/agent/config/cli-flags#_enable_script_checks)
|
||||
set to `true` in order to enable Docker health checks.
|
||||
|
||||
- `gRPC + Interval` - These checks are intended for applications that support the standard
|
||||
|
@ -462,7 +462,7 @@ This is the only convention that Consul depends on. Any output of the script
|
|||
will be captured and stored in the `output` field.
|
||||
|
||||
In Consul 0.9.0 and later, the agent must be configured with
|
||||
[`enable_script_checks`](/docs/agent/config/agent-config-cli#_enable_script_checks) set to `true`
|
||||
[`enable_script_checks`](/docs/agent/config/cli-flags#_enable_script_checks) set to `true`
|
||||
in order to enable script checks.
|
||||
|
||||
## Initial Health Check Status
|
||||
|
@ -538,7 +538,7 @@ provided by the node will remain unchanged.
|
|||
|
||||
## Agent Certificates for TLS Checks
|
||||
|
||||
The [enable_agent_tls_for_checks](/docs/agent/config/agent-config-files#enable_agent_tls_for_checks)
|
||||
The [enable_agent_tls_for_checks](/docs/agent/config/config-files#enable_agent_tls_for_checks)
|
||||
agent configuration option can be utilized to have HTTP or gRPC health checks
|
||||
to use the agent's credentials when configured for TLS.
|
||||
|
||||
|
|
|
@ -21,9 +21,9 @@ are located in the `us-east-1` datacenter, and have no failing health checks.
|
|||
It's that simple!
|
||||
|
||||
There are a number of configuration options that are important for the DNS interface,
|
||||
specifically [`client_addr`](/docs/agent/config/agent-config-files#client_addr),[`ports.dns`](/docs/agent/config/agent-config-files#dns_port),
|
||||
[`recursors`](/docs/agent/config/agent-config-files#recursors),[`domain`](/docs/agent/config/agent-config-files#domain),
|
||||
[`alt_domain`](/docs/agent/config/agent-config-files#alt_domain), and [`dns_config`](/docs/agent/config/agent-config-files#dns_config).
|
||||
specifically [`client_addr`](/docs/agent/config/config-files#client_addr),[`ports.dns`](/docs/agent/config/config-files#dns_port),
|
||||
[`recursors`](/docs/agent/config/config-files#recursors),[`domain`](/docs/agent/config/config-files#domain),
|
||||
[`alt_domain`](/docs/agent/config/config-files#alt_domain), and [`dns_config`](/docs/agent/config/config-files#dns_config).
|
||||
By default, Consul will listen on 127.0.0.1:8600 for DNS queries in the `consul.`
|
||||
domain, without support for further DNS recursion. Please consult the
|
||||
[documentation on configuration options](/docs/agent/config),
|
||||
|
@ -32,7 +32,7 @@ specifically the configuration items linked above, for more details.
|
|||
There are a few ways to use the DNS interface. One option is to use a custom
|
||||
DNS resolver library and point it at Consul. Another option is to set Consul
|
||||
as the DNS server for a node and provide a
|
||||
[`recursors`](/docs/agent/config/agent-config-files#recursors) configuration so that non-Consul queries
|
||||
[`recursors`](/docs/agent/config/config-files#recursors) configuration so that non-Consul queries
|
||||
can also be resolved. The last method is to forward all queries for the "consul."
|
||||
domain to a Consul agent from the existing DNS server. Review the
|
||||
[DNS Forwarding tutorial](https://learn.hashicorp.com/tutorials/consul/dns-forwarding?utm_source=consul.io&utm_medium=docs) for examples.
|
||||
|
@ -296,15 +296,15 @@ are not truncated.
|
|||
## Alternative Domain
|
||||
|
||||
By default, Consul responds to DNS queries in the `consul` domain,
|
||||
but you can set a specific domain for responding to DNS queries by configuring the [`domain`](/docs/agent/config/agent-config-files#domain) parameter.
|
||||
but you can set a specific domain for responding to DNS queries by configuring the [`domain`](/docs/agent/config/config-files#domain) parameter.
|
||||
|
||||
In some instances, Consul may need to respond to queries in more than one domain,
|
||||
such as during a DNS migration or to distinguish between internal and external queries.
|
||||
|
||||
Consul versions 1.5.2+ can be configured to respond to DNS queries on an alternative domain
|
||||
through the [`alt_domain`](/docs/agent/config/agent-config-files#alt_domain) agent configuration
|
||||
through the [`alt_domain`](/docs/agent/config/config-files#alt_domain) agent configuration
|
||||
option. As of Consul versions 1.11.0+, Consul's DNS response will use the same domain as was used in the query;
|
||||
in prior versions, the response may use the primary [`domain`](/docs/agent/config/agent-config-files#domain) no matter which
|
||||
in prior versions, the response may use the primary [`domain`](/docs/agent/config/config-files#domain) no matter which
|
||||
domain was used in the query.
|
||||
|
||||
In the following example, the `alt_domain` parameter is set to `test-domain`:
|
||||
|
@ -331,7 +331,7 @@ machine.node.dc1.test-domain. 0 IN TXT "consul-network-segment="
|
|||
```
|
||||
|
||||
-> **PTR queries:** Responses to PTR queries (`<ip>.in-addr.arpa.`) will always use the
|
||||
[primary domain](/docs/agent/config/agent-config-files#domain) (not the alternative domain),
|
||||
[primary domain](/docs/agent/config/config-files#domain) (not the alternative domain),
|
||||
as there is no way for the query to specify a domain.
|
||||
|
||||
## Caching
|
||||
|
@ -346,8 +346,8 @@ for [DNS caching](https://learn.hashicorp.com/tutorials/consul/dns-caching).
|
|||
By default, Consul DNS queries will return a node's local address, even when
|
||||
being queried from a remote datacenter. If you need to use a different address
|
||||
to reach a node from outside its datacenter, you can configure this behavior
|
||||
using the [`advertise-wan`](/docs/agent/config/agent-config-cli#_advertise-wan) and
|
||||
[`translate_wan_addrs`](/docs/agent/config/agent-config-files#translate_wan_addrs) configuration
|
||||
using the [`advertise-wan`](/docs/agent/config/cli-flags#_advertise-wan) and
|
||||
[`translate_wan_addrs`](/docs/agent/config/config-files#translate_wan_addrs) configuration
|
||||
options.
|
||||
|
||||
## Namespaced/Partitioned Services <EnterpriseAlert inline />
|
||||
|
@ -363,7 +363,7 @@ services from other namespaces or partitions the following form can be used:
|
|||
|
||||
This is the canonical name of a Consul Enterprise service. Currently all parts must be
|
||||
present - in a future version (once the
|
||||
[`prefer_namespace` configuration](/docs/agent/config/agent-config-files#dns_prefer_namespace) has been
|
||||
[`prefer_namespace` configuration](/docs/agent/config/config-files#dns_prefer_namespace) has been
|
||||
deprecated), the namespace, partition and datacenter components will become optional
|
||||
and may be individually omitted to default to the `default` namespace, local partition
|
||||
or local datacenter respectively.
|
||||
|
@ -377,7 +377,7 @@ are enabled, you must first create ACL tokens with the necessary policies.
|
|||
Consul agents resolve DNS requests using one of the preconfigured tokens below,
|
||||
listed in order of precedence:
|
||||
|
||||
1. The agent's [`default` token](/docs/agent/config/agent-config-files#acl_tokens_default).
|
||||
1. The agent's [`default` token](/docs/agent/config/config-files#acl_tokens_default).
|
||||
2. The built-in [`anonymous` token](/docs/security/acl/acl-system#builtin-tokens).
|
||||
Because the anonymous token is used when any request is made to Consul without
|
||||
explicitly specifying a token, production deployments should not apply policies
|
||||
|
|
|
@ -39,7 +39,7 @@ privileges on one key for developers to update the value related to their
|
|||
application.
|
||||
|
||||
The datastore itself is located on the Consul servers in the [data
|
||||
directory](/docs/agent/config/agent-config-cli#_data_dir). To ensure data is not lost in
|
||||
directory](/docs/agent/config/cli-flags#_data_dir). To ensure data is not lost in
|
||||
the event of a complete outage, use the [`consul snapshot`](/commands/snapshot/restore) feature to backup the data.
|
||||
|
||||
## Using Consul KV
|
||||
|
@ -48,7 +48,7 @@ Objects are opaque to Consul, meaning there are no restrictions on the type of
|
|||
object stored in a key/value entry. The main restriction on an object is size -
|
||||
the maximum is 512 KB. Due to the maximum object size and main use cases, you
|
||||
should not need extra storage; the general [sizing
|
||||
recommendations](/docs/agent/config/agent-config-files#kv_max_value_size)
|
||||
recommendations](/docs/agent/config/config-files#kv_max_value_size)
|
||||
are usually sufficient.
|
||||
|
||||
Keys, like objects are not restricted by type and can include any character.
|
||||
|
|
|
@ -20,7 +20,7 @@ Watches are implemented using blocking queries in the [HTTP API](/api).
|
|||
Agents automatically make the proper API calls to watch for changes
|
||||
and inform a handler when the data view has updated.
|
||||
|
||||
Watches can be configured as part of the [agent's configuration](/docs/agent/config/agent-config-files#watches),
|
||||
Watches can be configured as part of the [agent's configuration](/docs/agent/config/config-files#watches),
|
||||
causing them to run once the agent is initialized. Reloading the agent configuration
|
||||
allows for adding or removing watches dynamically.
|
||||
|
||||
|
|
|
@ -62,7 +62,7 @@ however there are some important inputs worth highlighting:
|
|||
This is where you include application containers.
|
||||
- `port` is the port that your application listens on. This should be set to a
|
||||
string, not an integer, i.e. `port = "9090"`, not `port = 9090`.
|
||||
- `retry_join` is passed to the [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) option for the Consul agent. This tells
|
||||
- `retry_join` is passed to the [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) option for the Consul agent. This tells
|
||||
the agent the location of your Consul servers so that it can join the Consul cluster.
|
||||
|
||||
-> **NOTE:** If your tasks run in a public subnet, they must have `assign_public_ip = true`
|
||||
|
|
|
@ -25,14 +25,14 @@ For more experience leveraging Consul's audit logging functionality, explore our
|
|||
HashiCorp Learn tutorial [Capture Consul Events with Audit Logging](https://learn.hashicorp.com/tutorials/consul/audit-logging).
|
||||
|
||||
For detailed configuration information on configuring the Consul Enterprise's audit
|
||||
logging, review the Consul [Audit Log](https://www.consul.io/docs/agent/config/agent-config-files#audit)
|
||||
logging, review the Consul [Audit Log](https://www.consul.io/docs/agent/config/config-files#audit)
|
||||
documentation.
|
||||
|
||||
## Example Configuration
|
||||
|
||||
Audit logging must be enabled on every agent in order to accurately capture all
|
||||
operations performed through the HTTP API. To enable logging, add
|
||||
the [`audit`](/docs/agent/config/agent-config-files#audit) stanza to the agent's configuration.
|
||||
the [`audit`](/docs/agent/config/config-files#audit) stanza to the agent's configuration.
|
||||
|
||||
-> **Note**: Consul only logs operations which are initiated via the HTTP API.
|
||||
The audit log does not record operations that take place over the internal RPC
|
||||
|
|
|
@ -36,7 +36,7 @@ When using these binaries no further action is necessary to configure the licens
|
|||
### Binaries Without Built In Licenses
|
||||
|
||||
For Consul Enterprise 1.10.0 or greater, binaries that do not include built in licenses a license must be available at the time the agent starts.
|
||||
For server agents this means that they must either have the [`license_path`](/docs/agent/config/agent-config-files#license_path)
|
||||
For server agents this means that they must either have the [`license_path`](/docs/agent/config/config-files#license_path)
|
||||
configuration set or have a license configured in the servers environment with the `CONSUL_LICENSE` or
|
||||
`CONSUL_LICENSE_PATH` environment variables. Both the configuration item and the `CONSUL_LICENSE_PATH`
|
||||
environment variable point to a file containing the license whereas the `CONSUL_LICENSE` environment
|
||||
|
@ -55,9 +55,9 @@ to retrieve the license automatically under specific circumstances.
|
|||
When a client agent starts without a license in its configuration or environment, it will try to retrieve the
|
||||
license from the servers via RPCs. That RPC always requires a valid non-anonymous ACL token to authorize the
|
||||
request but the token doesn't need any particular permissions. As the license is required before the client
|
||||
actually joins the cluster, where to make those RPC requests to is inferred from the [`start_join`](/docs/agent/config/agent-config-files#start_join)
|
||||
or [`retry_join`](/docs/agent/config/agent-config-files#retry_join) configurations. If those are both unset or no
|
||||
[`agent` token](/docs/agent/config/agent-config-files#acl_tokens_agent) is set then the client agent will immediately shut itself down.
|
||||
actually joins the cluster, where to make those RPC requests to is inferred from the [`start_join`](/docs/agent/config/config-files#start_join)
|
||||
or [`retry_join`](/docs/agent/config/config-files#retry_join) configurations. If those are both unset or no
|
||||
[`agent` token](/docs/agent/config/config-files#acl_tokens_agent) is set then the client agent will immediately shut itself down.
|
||||
|
||||
If all preliminary checks pass the client agent will attempt to reach out to any server on its RPC port to
|
||||
request the license. These requests will be retried for up to 5 minutes and if it is unable to retrieve a
|
||||
|
|
|
@ -15,7 +15,7 @@ description: |-
|
|||
</EnterpriseAlert>
|
||||
|
||||
Consul requires full connectivity between all agents (servers and clients) in a
|
||||
[datacenter](/docs/agent/config/agent-config-cli#_datacenter) within a given
|
||||
[datacenter](/docs/agent/config/cli-flags#_datacenter) within a given
|
||||
LAN gossip pool. By default, all Consul agents will be a part of one shared Serf LAN
|
||||
gossip pool known as the `<default>` network segment, thus requiring full mesh
|
||||
connectivity within the datacenter.
|
||||
|
@ -46,7 +46,7 @@ Consul networking models and their capabilities.
|
|||
|
||||
**Cluster:** A set of Consul servers forming a Raft quorum along with a
|
||||
collection of Consul clients, all set to the same
|
||||
[datacenter](/docs/agent/config/agent-config-cli#_datacenter), and joined together to form
|
||||
[datacenter](/docs/agent/config/cli-flags#_datacenter), and joined together to form
|
||||
what we will call a "local cluster". Consul clients discover the Consul servers
|
||||
in their local cluster through the gossip mechanism and make RPC requests to
|
||||
them. LAN Gossip (OSS) is an open intra-cluster networking model, and Network
|
||||
|
@ -73,7 +73,7 @@ group of agents to only connect with the agents in its segment.
|
|||
|
||||
Server agents are members of all segments. The datacenter includes a `<default>`
|
||||
segment, as well as additional segments defined in the
|
||||
[`segments`](/docs/agent/config/agent-config-files#segments) server agent configuration option.
|
||||
[`segments`](/docs/agent/config/config-files#segments) server agent configuration option.
|
||||
Each additional segment is defined by:
|
||||
|
||||
- a non-empty name
|
||||
|
@ -130,19 +130,19 @@ segments = [
|
|||
|
||||
</CodeTabs>
|
||||
|
||||
The server [agent configuration](/docs/agent/config/agent-config-files) options relevant to network
|
||||
The server [agent configuration](/docs/agent/config/config-files) options relevant to network
|
||||
segments are:
|
||||
|
||||
- [`ports.serf_lan`](/docs/agent/config/agent-config-files#serf_lan_port): The Serf LAN port on this server
|
||||
- [`ports.serf_lan`](/docs/agent/config/config-files#serf_lan_port): The Serf LAN port on this server
|
||||
for the `<default>` network segment's gossip pool.
|
||||
- [`segments`](/docs/agent/config/agent-config-files#segments): A list of user-defined network segments
|
||||
- [`segments`](/docs/agent/config/config-files#segments): A list of user-defined network segments
|
||||
on this server, including their names and Serf LAN ports.
|
||||
|
||||
## Client Configuration
|
||||
|
||||
Each client agent can only be a member of one segment at a time. This will be the
|
||||
`<default>` segment unless otherwise specified in the agent's
|
||||
[`segment`](/docs/agent/config/agent-config-cli#_segment) agent configuration option.
|
||||
[`segment`](/docs/agent/config/cli-flags#_segment) agent configuration option.
|
||||
|
||||
### Join a Client to a Segment ((#join_a_client_to_a_segment))
|
||||
|
||||
|
@ -155,14 +155,14 @@ configured segment.
|
|||
|
||||
Clients A and B specify the same segment S. Client B is already joined to the segment S
|
||||
LAN gossip pool. Client A wants to join via Client B. In order to do so, Client A
|
||||
must connect to Client B's configured [Serf LAN port](/docs/agent/config/agent-config-files#serf_lan_port).
|
||||
must connect to Client B's configured [Serf LAN port](/docs/agent/config/config-files#serf_lan_port).
|
||||
|
||||
</Tab>
|
||||
<Tab heading="Join via a server">
|
||||
|
||||
Client A specifies segment S and wants to join the segment S gossip pool via Server 1.
|
||||
In order to do so, Client A must connect to Server 1's configured [Serf LAN port
|
||||
for segment S](/docs/agent/config/agent-config-files#segment_port).
|
||||
for segment S](/docs/agent/config/config-files#segment_port).
|
||||
|
||||
</Tab>
|
||||
</Tabs>
|
||||
|
@ -172,12 +172,12 @@ of precedence:
|
|||
|
||||
1. **Specify an explicit port in the join address**. This can be done at the CLI when starting
|
||||
the agent (e.g., `consul agent -retry-join "client-b-address:8303"`), or in the agent's
|
||||
configuration using the [retry-join option](/docs/agent/config/agent-config-files#retry_join). This method
|
||||
configuration using the [retry-join option](/docs/agent/config/config-files#retry_join). This method
|
||||
is not compatible with [cloud auto-join](/docs/install/cloud-auto-join#auto-join-with-network-segments).
|
||||
|
||||
2. **Specify an alternate Serf LAN port for the agent**. This can be done at the CLI when starting
|
||||
the agent (e.g., `consul agent -retry-join "client-b-address" -serf-lan-port 8303`), or in
|
||||
the agent's configuration using the [serf_lan](/docs/agent/config/agent-config-files#serf_lan_port) option.
|
||||
the agent's configuration using the [serf_lan](/docs/agent/config/config-files#serf_lan_port) option.
|
||||
When a Serf LAN port is not explicitly specified in the join address, the agent will attempt to
|
||||
join the target host at the Serf LAN port specified in CLI or agent configuration.
|
||||
|
||||
|
@ -222,15 +222,15 @@ ports = {
|
|||
|
||||
</CodeTabs>
|
||||
|
||||
The client [agent configuration](/docs/agent/config/agent-config-files) options relevant to network
|
||||
The client [agent configuration](/docs/agent/config/config-files) options relevant to network
|
||||
segments are:
|
||||
|
||||
- [`segment`](/docs/agent/config/agent-config-files#segment-2): The name of the network segment this
|
||||
- [`segment`](/docs/agent/config/config-files#segment-2): The name of the network segment this
|
||||
client agent belongs to.
|
||||
- [`ports.serf_lan`](/docs/agent/config/agent-config-files#serf_lan_port):
|
||||
- [`ports.serf_lan`](/docs/agent/config/config-files#serf_lan_port):
|
||||
Serf LAN port for the above segment on this client. This is not required
|
||||
to match the configured Serf LAN port for other agents on this segment.
|
||||
- [`retry_join`](/docs/agent/config/agent-config-files#retry_join) or
|
||||
[`start_join`](/docs/agent/config/agent-config-files#start_join): A list of agent addresses to join
|
||||
- [`retry_join`](/docs/agent/config/config-files#retry_join) or
|
||||
[`start_join`](/docs/agent/config/config-files#start_join): A list of agent addresses to join
|
||||
when starting. Ensure the correct Serf LAN port for this segment is used when joining
|
||||
the LAN gossip pool using one of the [available configuration methods](#join_a_client_to_a_segment).
|
||||
|
|
|
@ -20,5 +20,5 @@ however, they do not take part in quorum election operations. Expanding your Con
|
|||
reads without impacting write latency.
|
||||
|
||||
For more details, review the [Consul server configuration](/docs/agent/config)
|
||||
documentation and the [-read-replica](/docs/agent/config/agent-config-cli#_read_replica)
|
||||
documentation and the [-read-replica](/docs/agent/config/cli-flags#_read_replica)
|
||||
configuration flag.
|
||||
|
|
|
@ -30,16 +30,16 @@ as data loss is inevitable in a failure scenario. Please refer to the
|
|||
Manual bootstrapping with `-bootstrap` is not recommended in
|
||||
newer versions of Consul (0.5 and newer) as it is more error-prone.
|
||||
Instead you should use automatic bootstrapping
|
||||
with [`-bootstrap-expect`](/docs/agent/config/agent-config-cli#_bootstrap_expect).
|
||||
with [`-bootstrap-expect`](/docs/agent/config/cli-flags#_bootstrap_expect).
|
||||
|
||||
## Bootstrapping the Servers
|
||||
|
||||
The recommended way to bootstrap the servers is to use the [`-bootstrap-expect`](/docs/agent/config/agent-config-cli#_bootstrap_expect)
|
||||
The recommended way to bootstrap the servers is to use the [`-bootstrap-expect`](/docs/agent/config/cli-flags#_bootstrap_expect)
|
||||
configuration option. This option informs Consul of the expected number of
|
||||
server nodes and automatically bootstraps when that many servers are available. To prevent
|
||||
inconsistencies and split-brain (clusters where multiple servers consider
|
||||
themselves leader) situations, you should either specify the same value for
|
||||
[`-bootstrap-expect`](/docs/agent/config/agent-config-cli#_bootstrap_expect)
|
||||
[`-bootstrap-expect`](/docs/agent/config/cli-flags#_bootstrap_expect)
|
||||
or specify no value at all on all the servers. Only servers that specify a value will attempt to bootstrap the cluster.
|
||||
|
||||
Suppose we are starting a three server cluster. We can start `Node A`, `Node B`, and `Node C` with each
|
||||
|
@ -61,11 +61,11 @@ You can trigger leader election by joining the servers together, to create a clu
|
|||
There are multiple options for joining the servers. Choose the method which best suits your environment and specific use case.
|
||||
|
||||
- Specify a list of servers with
|
||||
[-join](/docs/agent/config/agent-config-cli#_join) and
|
||||
[start_join](/docs/agent/config/agent-config-files#start_join)
|
||||
[-join](/docs/agent/config/cli-flags#_join) and
|
||||
[start_join](/docs/agent/config/config-files#start_join)
|
||||
options.
|
||||
- Specify a list of servers with [-retry-join](/docs/agent/config/agent-config-cli#_retry_join) option.
|
||||
- Use automatic joining by tag for supported cloud environments with the [-retry-join](/docs/agent/config/agent-config-cli#_retry_join) option.
|
||||
- Specify a list of servers with [-retry-join](/docs/agent/config/cli-flags#_retry_join) option.
|
||||
- Use automatic joining by tag for supported cloud environments with the [-retry-join](/docs/agent/config/cli-flags#_retry_join) option.
|
||||
|
||||
All three methods can be set in the agent configuration file or
|
||||
the command line flag.
|
||||
|
|
|
@ -69,7 +69,7 @@ to use port `8303` as its Serf LAN port prior to attempting to join the cluster.
|
|||
<Tab heading="Agent configuration">
|
||||
|
||||
The following example configuration overrides the default Serf LAN port using the
|
||||
[`ports.serf_lan`](/docs/agent/config/agent-config-files#serf_lan_port) configuration option.
|
||||
[`ports.serf_lan`](/docs/agent/config/config-files#serf_lan_port) configuration option.
|
||||
|
||||
<CodeBlockConfig filename="client-config.hcl">
|
||||
|
||||
|
@ -85,7 +85,7 @@ ports {
|
|||
<Tab heading="Command-line flag">
|
||||
|
||||
The following example overrides the default Serf LAN port using the
|
||||
[`-serf-lan-port`](/docs/agent/config/agent-config-cli#_serf_lan_port) command line flag.
|
||||
[`-serf-lan-port`](/docs/agent/config/cli-flags#_serf_lan_port) command line flag.
|
||||
|
||||
```shell
|
||||
$ consul agent -serf-lan-port=8303 -retry-join "provider=..."
|
||||
|
|
|
@ -23,7 +23,7 @@ storing the cluster state. The client nodes are mostly stateless and rely on the
|
|||
server nodes, so they can be started easily.
|
||||
|
||||
Manual bootstrapping requires that the first server that is deployed in a new
|
||||
datacenter provide the [`-bootstrap` configuration option](/docs/agent/config/agent-config-cli#_bootstrap).
|
||||
datacenter provide the [`-bootstrap` configuration option](/docs/agent/config/cli-flags#_bootstrap).
|
||||
This option allows the server
|
||||
to assert leadership of the cluster without agreement from any other server.
|
||||
This is necessary because at this point, there are no other servers running in
|
||||
|
|
|
@ -18,7 +18,7 @@ reads work from a fully in-memory data store that is optimized for concurrent ac
|
|||
|
||||
## Minimum Server Requirements ((#minimum))
|
||||
|
||||
In Consul 0.7, the default server [performance parameters](/docs/agent/config/agent-config-files#performance)
|
||||
In Consul 0.7, the default server [performance parameters](/docs/agent/config/config-files#performance)
|
||||
were tuned to allow Consul to run reliably (but relatively slowly) on a server cluster of three
|
||||
[AWS t2.micro](https://aws.amazon.com/ec2/instance-types/) instances. These thresholds
|
||||
were determined empirically using a leader instance that was under sufficient read, write,
|
||||
|
@ -43,7 +43,7 @@ The default performance configuration is equivalent to this:
|
|||
## Production Server Requirements ((#production))
|
||||
|
||||
When running Consul 0.7 and later in production, it is recommended to configure the server
|
||||
[performance parameters](/docs/agent/config/agent-config-files#performance) back to Consul's original
|
||||
[performance parameters](/docs/agent/config/config-files#performance) back to Consul's original
|
||||
high-performance settings. This will let Consul servers detect a failed leader and complete
|
||||
leader elections much more quickly than the default configuration which extends key Raft
|
||||
timeouts by a factor of 5, so it can be quite slow during these events.
|
||||
|
@ -103,14 +103,14 @@ Here are some general recommendations:
|
|||
issues between the servers or insufficient CPU resources. Users in cloud environments
|
||||
often bump their servers up to the next instance class with improved networking
|
||||
and CPU until leader elections stabilize, and in Consul 0.7 or later the [performance
|
||||
parameters](/docs/agent/config/agent-config-files#performance) configuration now gives you tools
|
||||
parameters](/docs/agent/config/config-files#performance) configuration now gives you tools
|
||||
to trade off performance instead of upsizing servers. You can use the [`consul.raft.leader.lastContact`
|
||||
telemetry](/docs/agent/telemetry#leadership-changes) to observe how the Raft timing is
|
||||
performing and guide the decision to de-tune Raft performance or add more powerful
|
||||
servers.
|
||||
|
||||
- For DNS-heavy workloads, configuring all Consul agents in a cluster with the
|
||||
[`allow_stale`](/docs/agent/config/agent-config-files#allow_stale) configuration option will allow reads to
|
||||
[`allow_stale`](/docs/agent/config/config-files#allow_stale) configuration option will allow reads to
|
||||
scale across all Consul servers, not just the leader. Consul 0.7 and later enables stale reads
|
||||
for DNS by default. See [Stale Reads](https://learn.hashicorp.com/tutorials/consul/dns-caching#stale-reads) in the
|
||||
[DNS Caching](https://learn.hashicorp.com/tutorials/consul/dns-caching) guide for more details. It's also good to set
|
||||
|
@ -121,7 +121,7 @@ Here are some general recommendations:
|
|||
[stale consistency mode](/api/features/consistency#stale) available to allow reads to scale
|
||||
across all the servers and not just be forwarded to the leader.
|
||||
|
||||
- In Consul 0.9.3 and later, a new [`limits`](/docs/agent/config/agent-config-files#limits) configuration is
|
||||
- In Consul 0.9.3 and later, a new [`limits`](/docs/agent/config/config-files#limits) configuration is
|
||||
available on Consul clients to limit the RPC request rate they are allowed to make against the
|
||||
Consul servers. After hitting the limit, requests will start to return rate limit errors until
|
||||
time has passed and more requests are allowed. Configuring this across the cluster can help with
|
||||
|
@ -156,11 +156,11 @@ For **write-heavy** workloads, the total RAM available for overhead must approxi
|
|||
RAM NEEDED = number of keys * average key size * 2-3x
|
||||
```
|
||||
|
||||
Since writes must be synced to disk (persistent storage) on a quorum of servers before they are committed, deploying a disk with high write throughput (or an SSD) will enhance performance on the write side. ([Documentation](/docs/agent/config/agent-config-cli#_data_dir))
|
||||
Since writes must be synced to disk (persistent storage) on a quorum of servers before they are committed, deploying a disk with high write throughput (or an SSD) will enhance performance on the write side. ([Documentation](/docs/agent/config/cli-flags#_data_dir))
|
||||
|
||||
For a **read-heavy** workload, configure all Consul server agents with the `allow_stale` DNS option, or query the API with the `stale` [consistency mode](/api/features/consistency). By default, all queries made to the server are RPC forwarded to and serviced by the leader. By enabling stale reads, any server will respond to any query, thereby reducing overhead on the leader. Typically, the stale response is `100ms` or less from consistent mode but it drastically improves performance and reduces latency under high load.
|
||||
|
||||
If the leader server is out of memory or the disk is full, the server eventually stops responding, loses its election and cannot move past its last commit time. However, by configuring `max_stale` and setting it to a large value, Consul will continue to respond to queries during such outage scenarios. ([max_stale documentation](/docs/agent/config/agent-config-files#max_stale)).
|
||||
If the leader server is out of memory or the disk is full, the server eventually stops responding, loses its election and cannot move past its last commit time. However, by configuring `max_stale` and setting it to a large value, Consul will continue to respond to queries during such outage scenarios. ([max_stale documentation](/docs/agent/config/config-files#max_stale)).
|
||||
|
||||
It should be noted that `stale` is not appropriate for coordination where strong consistency is important (i.e. locking or application leader election). For critical cases, the optional `consistent` API query mode is required for true linearizability; the trade off is that this turns a read into a full quorum write so requires more resources and takes longer.
|
||||
|
||||
|
@ -168,7 +168,7 @@ It should be noted that `stale` is not appropriate for coordination where strong
|
|||
|
||||
Consul’s agents use network sockets for communicating with the other nodes (gossip) and with the server agent. In addition, file descriptors are also opened for watch handlers, health checks, and log files. For a **write heavy** cluster, the `ulimit` size must be increased from the default value (`1024`) to prevent the leader from running out of file descriptors.
|
||||
|
||||
To prevent any CPU spikes from a misconfigured client, RPC requests to the server should be [rate limited](/docs/agent/config/agent-config-files#limits)
|
||||
To prevent any CPU spikes from a misconfigured client, RPC requests to the server should be [rate limited](/docs/agent/config/config-files#limits)
|
||||
|
||||
~> **NOTE** Rate limiting is configured on the client agent only.
|
||||
|
||||
|
@ -191,8 +191,8 @@ Smearing requests over 30s is sufficient to bring RPC load to a reasonable level
|
|||
in all but the very largest clusters, but the extra CPU load from cryptographic
|
||||
operations could impact the server's normal work. To limit that, Consul since
|
||||
1.4.1 exposes two ways to limit the impact Certificate signing has on the leader
|
||||
[`csr_max_per_second`](/docs/agent/config/agent-config-files#ca_csr_max_per_second) and
|
||||
[`csr_max_concurrent`](/docs/agent/config/agent-config-files#ca_csr_max_concurrent).
|
||||
[`csr_max_per_second`](/docs/agent/config/config-files#ca_csr_max_per_second) and
|
||||
[`csr_max_concurrent`](/docs/agent/config/config-files#ca_csr_max_concurrent).
|
||||
|
||||
By default we set a limit of 50 per second which is reasonable on modest
|
||||
hardware but may be too low and impact rotation times if more than 1500 service
|
||||
|
|
|
@ -55,4 +55,4 @@ the Serf WAN port (TCP/UDP) to be listening on both WAN and LAN interfaces. See
|
|||
**Server RPC** This is used by servers to handle incoming
|
||||
requests from other agents.
|
||||
|
||||
Note, the default ports can be changed in the [agent configuration](/docs/agent/config/agent-config-files#ports).
|
||||
Note, the default ports can be changed in the [agent configuration](/docs/agent/config/config-files#ports).
|
||||
|
|
|
@ -199,5 +199,5 @@ To update any settings under these keys, you must use Consul's [Update CA Config
|
|||
To renew the Vault token, use the [`vault token renew`](https://www.vaultproject.io/docs/commands/token/renew) CLI command
|
||||
or API.
|
||||
|
||||
[`ca_config`]: /docs/agent/config/agent-config-files#connect_ca_config
|
||||
[`ca_provider`]: /docs/agent/config/agent-config-files#connect_ca_provider
|
||||
[`ca_config`]: /docs/agent/config/config-files#connect_ca_config
|
||||
[`ca_provider`]: /docs/agent/config/config-files#connect_ca_provider
|
||||
|
|
|
@ -57,7 +57,7 @@ Use these links to navigate to a particular top-level stanza.
|
|||
the prefix will be `<helm release name>-consul`.
|
||||
|
||||
- `domain` ((#v-global-domain)) (`string: consul`) - The domain Consul will answer DNS queries for
|
||||
(see `-domain` (https://consul.io/docs/agent/config/agent-config-cli#_domain)) and the domain services synced from
|
||||
(see `-domain` (https://consul.io/docs/agent/config/cli-flags#_domain)) and the domain services synced from
|
||||
Consul into Kubernetes will have, e.g. `service-name.service.consul`.
|
||||
|
||||
- `adminPartitions` ((#v-global-adminpartitions)) - <EnterpriseAlert inline /> Enabling `adminPartitions` allows creation of Admin Partitions in Kubernetes clusters.
|
||||
|
@ -215,7 +215,7 @@ Use these links to navigate to a particular top-level stanza.
|
|||
```
|
||||
|
||||
- `gossipEncryption` ((#v-global-gossipencryption)) - Configures Consul's gossip encryption key.
|
||||
(see `-encrypt` (https://consul.io/docs/agent/config/agent-config-cli#_encrypt)).
|
||||
(see `-encrypt` (https://consul.io/docs/agent/config/cli-flags#_encrypt)).
|
||||
By default, gossip encryption is not enabled. The gossip encryption key may be set automatically or manually.
|
||||
The recommended method is to automatically generate the key.
|
||||
To automatically generate and set a gossip encryption key, set autoGenerate to true.
|
||||
|
@ -246,7 +246,7 @@ Use these links to navigate to a particular top-level stanza.
|
|||
|
||||
- `recursors` ((#v-global-recursors)) (`array<string>: []`) - A list of addresses of upstream DNS servers that are used to recursively resolve DNS queries.
|
||||
These values are given as `-recursor` flags to Consul servers and clients.
|
||||
See https://www.consul.io/docs/agent/config/agent-config-cli#_recursor for more details.
|
||||
See https://www.consul.io/docs/agent/config/cli-flags#_recursor for more details.
|
||||
If this is an empty array (the default), then Consul DNS will only resolve queries for the Consul top level domain (by default `.consul`).
|
||||
|
||||
- `tls` ((#v-global-tls)) - Enables TLS (https://learn.hashicorp.com/tutorials/consul/tls-encryption-secure)
|
||||
|
@ -778,7 +778,7 @@ Use these links to navigate to a particular top-level stanza.
|
|||
- `image` ((#v-client-image)) (`string: null`) - The name of the Docker image (including any tag) for the containers
|
||||
running Consul client agents.
|
||||
|
||||
- `join` ((#v-client-join)) (`array<string>: null`) - A list of valid `-retry-join` values (https://consul.io/docs/agent/config/agent-config-files#retry-join).
|
||||
- `join` ((#v-client-join)) (`array<string>: null`) - A list of valid `-retry-join` values (https://consul.io/docs/agent/config/config-files#retry-join).
|
||||
If this is `null` (default), then the clients will attempt to automatically
|
||||
join the server cluster running within Kubernetes.
|
||||
This means that with `server.enabled` set to true, clients will automatically
|
||||
|
@ -799,7 +799,7 @@ Use these links to navigate to a particular top-level stanza.
|
|||
required for Connect.
|
||||
|
||||
- `nodeMeta` ((#v-client-nodemeta)) - nodeMeta specifies an arbitrary metadata key/value pair to associate with the node
|
||||
(see https://www.consul.io/docs/agent/config/agent-config-cli#_node_meta)
|
||||
(see https://www.consul.io/docs/agent/config/cli-flags#_node_meta)
|
||||
|
||||
- `pod-name` ((#v-client-nodemeta-pod-name)) (`string: ${HOSTNAME}`)
|
||||
|
||||
|
@ -1152,7 +1152,7 @@ Use these links to navigate to a particular top-level stanza.
|
|||
will inherit from `global.metrics.enabled` value.
|
||||
|
||||
- `provider` ((#v-ui-metrics-provider)) (`string: prometheus`) - Provider for metrics. See
|
||||
https://www.consul.io/docs/agent/config/agent-config-files#ui_config_metrics_provider
|
||||
https://www.consul.io/docs/agent/config/config-files#ui_config_metrics_provider
|
||||
This value is only used if `ui.enabled` is set to true.
|
||||
|
||||
- `baseURL` ((#v-ui-metrics-baseurl)) (`string: http://prometheus-server`) - baseURL is the URL of the prometheus server, usually the service URL.
|
||||
|
|
|
@ -62,7 +62,7 @@ Kubernetes cluster.
|
|||
|
||||
The server agents are run as a **StatefulSet**, using persistent volume
|
||||
claims to store the server state. This also ensures that the
|
||||
[node ID](/docs/agent/config/agent-config-cli#_node_id) is persisted so that servers
|
||||
[node ID](/docs/agent/config/cli-flags#_node_id) is persisted so that servers
|
||||
can be rescheduled onto new IP addresses without causing issues. The server agents
|
||||
are configured with
|
||||
[anti-affinity](https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity)
|
||||
|
|
|
@ -22,7 +22,7 @@ you want the clients to be exposed on the Kubernetes internal node IPs (`true`)
|
|||
their pod IPs (`false`).
|
||||
|
||||
Finally, `client.join` is set to an array of valid
|
||||
[`-retry-join` values](/docs/agent/config/agent-config-cli#retry-join). In the
|
||||
[`-retry-join` values](/docs/agent/config/cli-flags#retry-join). In the
|
||||
example above, a fake [cloud auto-join](/docs/agent/cloud-auto-join)
|
||||
value is specified. This should be set to resolve to the proper addresses of
|
||||
your existing Consul cluster.
|
||||
|
|
|
@ -271,8 +271,8 @@ The automatically generated federation secret contains:
|
|||
- **Consul server config** - This is a JSON snippet that must be used as part of the server config for secondary datacenters.
|
||||
It sets:
|
||||
|
||||
- [`primary_datacenter`](/docs/agent/config/agent-config-files#primary_datacenter) to the name of the primary datacenter.
|
||||
- [`primary_gateways`](/docs/agent/config/agent-config-files#primary_gateways) to an array of IPs or hostnames
|
||||
- [`primary_datacenter`](/docs/agent/config/config-files#primary_datacenter) to the name of the primary datacenter.
|
||||
- [`primary_gateways`](/docs/agent/config/config-files#primary_gateways) to an array of IPs or hostnames
|
||||
for the mesh gateways in the primary datacenter. These are the addresses that
|
||||
Consul servers in secondary clusters will use to communicate with the primary
|
||||
datacenter.
|
||||
|
|
|
@ -91,7 +91,7 @@ The following sections detail how to export this data.
|
|||
==> Saved dc1-client-consul-0-key.pem
|
||||
```
|
||||
|
||||
Or use the [auto_encrypt](/docs/agent/config/agent-config-files#auto_encrypt) feature.
|
||||
Or use the [auto_encrypt](/docs/agent/config/config-files#auto_encrypt) feature.
|
||||
|
||||
### Mesh Gateway Addresses
|
||||
|
||||
|
|
|
@ -61,7 +61,7 @@ tls {
|
|||
|
||||
The `consul` block is used to configure Consul-Terraform-Sync connection with a Consul agent to perform queries to the Consul Catalog and Consul KV pertaining to task execution.
|
||||
|
||||
-> **Note:** Use HTTP/2 to improve Consul-Terraform-Sync performance when communicating with the local Consul process. [TLS/HTTPS](/docs/agent/config/agent-config-files) must be configured for the local Consul with the [cert_file](/docs/agent/config/agent-config-filess#cert_file) and [key_file](/docs/agent/config/agent-config-files#key_file) parameters set. For the Consul-Terraform-Sync configuration, set `tls.enabled = true` and set the `address` parameter to the HTTPS URL, e.g., `address = example.consul.com:8501`. If using self-signed certificates for Consul, you will also need to set `tls.verify = false` or add the certificate to `ca_cert` or `ca_path`.
|
||||
-> **Note:** Use HTTP/2 to improve Consul-Terraform-Sync performance when communicating with the local Consul process. [TLS/HTTPS](/docs/agent/config/config-files) must be configured for the local Consul with the [cert_file](/docs/agent/config/config-filess#cert_file) and [key_file](/docs/agent/config/config-files#key_file) parameters set. For the Consul-Terraform-Sync configuration, set `tls.enabled = true` and set the `address` parameter to the HTTPS URL, e.g., `address = example.consul.com:8501`. If using self-signed certificates for Consul, you will also need to set `tls.verify = false` or add the certificate to `ca_cert` or `ca_path`.
|
||||
|
||||
To read more on suggestions for configuring the Consul agent, see [run an agent](/docs/nia/installation/requirements#run-an-agent).
|
||||
|
||||
|
@ -80,7 +80,7 @@ consul {
|
|||
- `enabled` - (bool)
|
||||
- `username` - (string)
|
||||
- `password` - (string)
|
||||
- `tls` - Configure TLS to use a secure client connection with Consul. Using HTTP/2 can solve issues related to hitting Consul's maximum connection limits, as well as improve efficiency when processing many blocking queries. This option is required for Consul-Terraform-Sync when connecting to a [Consul agent with TLS verification enabled for HTTPS connections](/docs/agent/config/agent-config-files#verify_incoming).
|
||||
- `tls` - Configure TLS to use a secure client connection with Consul. Using HTTP/2 can solve issues related to hitting Consul's maximum connection limits, as well as improve efficiency when processing many blocking queries. This option is required for Consul-Terraform-Sync when connecting to a [Consul agent with TLS verification enabled for HTTPS connections](/docs/agent/config/config-files#verify_incoming).
|
||||
- `enabled` - (bool) Enable TLS. Providing a value for any of the TLS options will enable this parameter implicitly.
|
||||
- `verify` - (bool: true) Enables TLS peer verification. The default is enabled, which will check the global certificate authority (CA) chain to make sure the certificates returned by Consul are valid.
|
||||
- If Consul is using a self-signed certificate that you have not added to the global CA chain, you can set this certificate with `ca_cert` or `ca_path`. Alternatively, you can disable SSL verification by setting `verify` to false. However, disabling verification is a potential security vulnerability.
|
||||
|
@ -98,7 +98,7 @@ consul {
|
|||
- `max_idle_conns` - (int: 0) The maximum number of total idle connections across all hosts. The limit is disabled by default.
|
||||
- `max_idle_conns_per_host` - (int: 100) The maximum number of idle connections per remote host. The majority of connections are established with one host, the Consul agent.
|
||||
- To achieve the shortest latency between a Consul service update to a task execution, configure `max_idle_conns_per_host` equal to or greater than the number of services in automation across all tasks.
|
||||
- This value should be lower than the configured [`http_max_conns_per_client`](https://www.consul.io/docs/agent/config/agent-config-files#http_max_conns_per_client) for the Consul agent. If `max_idle_conns_per_host` and the number of services in automation is greater than the Consul agent limit, Consul-Terraform-Sync may error due to connection limits (status code 429). You may increase the agent limit with caution. _Note: requests to the Consul agent made by Terraform subprocesses or any other process on the same host as Consul-Terraform-Sync will contribute to the Consul agent connection limit._
|
||||
- This value should be lower than the configured [`http_max_conns_per_client`](https://www.consul.io/docs/agent/config/config-files#http_max_conns_per_client) for the Consul agent. If `max_idle_conns_per_host` and the number of services in automation is greater than the Consul agent limit, Consul-Terraform-Sync may error due to connection limits (status code 429). You may increase the agent limit with caution. _Note: requests to the Consul agent made by Terraform subprocesses or any other process on the same host as Consul-Terraform-Sync will contribute to the Consul agent connection limit._
|
||||
- `tls_handshake_timeout` - (string: "10s") amount of time to wait to complete the TLS handshake.
|
||||
|
||||
## Service
|
||||
|
|
|
@ -35,7 +35,7 @@ The Consul agent must be running in order to dynamically update network devices.
|
|||
|
||||
When running a Consul agent with Consul-Terraform-Sync in production, we suggest to keep a few considerations in mind. Consul-Terraform-Sync uses [blocking queries](/api/features/blocking) to monitor task dependencies, like changes to registered services. This results in multiple long running TCP connections between Consul-Terraform-Sync and the agent to poll changes for each dependency. Monitoring a high number of services may quickly hit the default Consul agent connection limits.
|
||||
|
||||
There are 2 ways to fix this issue. The first and recommended fix is to use HTTP/2 (requires HTTPS) to communicate between Consul-Terraform-Sync and the Consul agent. When using HTTP/2 only a single connection is made and reused for all communications. See the [Consul Configuration section](/docs/nia/configuration#consul) for more. The other option is to configure [`limits.http_max_conns_per_client`](/docs/agent/config/agent-config-files#http_max_conns_per_client) for the agent to a reasonable value proportional to the number of services monitored by Consul-Terraform-Sync.
|
||||
There are 2 ways to fix this issue. The first and recommended fix is to use HTTP/2 (requires HTTPS) to communicate between Consul-Terraform-Sync and the Consul agent. When using HTTP/2 only a single connection is made and reused for all communications. See the [Consul Configuration section](/docs/nia/configuration#consul) for more. The other option is to configure [`limits.http_max_conns_per_client`](/docs/agent/config/config-files#http_max_conns_per_client) for the agent to a reasonable value proportional to the number of services monitored by Consul-Terraform-Sync.
|
||||
|
||||
### Register Services
|
||||
|
||||
|
|
|
@ -21,7 +21,7 @@ page_title: 1.9.0
|
|||
- **Active Health Checks for Consul on Kubernetes:** Consul service mesh now integrates with Kubernetes Readiness probes. This provides the ability to natively detect health status from Kubernetes via Readiness probe, and is then used for directing service mesh traffic.
|
||||
|
||||
- **Streaming:** This feature introduces a major architectural enhancement in how update notifications for blocking queries are delivered within the cluster. Streaming results in very significant reduction of CPU and network bandwidth usage on Consul servers in large-scale deployments. Streaming is particularly helpful in scaling blocking queries in Consul clusters that have rapid changes in service state.
|
||||
- Streaming is now available for the service health HTTP endpoint, and can be enabled through the [`use_streaming_backend`](https://www.consul.io/docs/agent/config/agent-config-files#use_streaming_backend) client configuration option, and [`rpc.enable_streaming`](https://www.consul.io/docs/agent/config/agent-config-files#rpc_enable_streaming) option on the servers. We will continue to enable streaming in more endpoints in subsequent releases.
|
||||
- Streaming is now available for the service health HTTP endpoint, and can be enabled through the [`use_streaming_backend`](https://www.consul.io/docs/agent/config/config-files#use_streaming_backend) client configuration option, and [`rpc.enable_streaming`](https://www.consul.io/docs/agent/config/config-files#rpc_enable_streaming) option on the servers. We will continue to enable streaming in more endpoints in subsequent releases.
|
||||
|
||||
## What's Changed
|
||||
|
||||
|
|
|
@ -89,7 +89,7 @@ and [Policies](/api/acl/policies).
|
|||
|
||||
~> **Warning**: In this document we use the deprecated
|
||||
configuration parameter `acl_datacenter`. In Consul 1.4 and newer the
|
||||
parameter has been updated to [`primary_datacenter`](/docs/agent/config/agent-config-files#primary_datacenter).
|
||||
parameter has been updated to [`primary_datacenter`](/docs/agent/config/config-files#primary_datacenter).
|
||||
|
||||
Consul provides an optional Access Control List (ACL) system which can be used to control
|
||||
access to data and APIs. The ACL is
|
||||
|
@ -129,7 +129,7 @@ token are automatically applied. The anonymous token is managed using the
|
|||
Tokens are bound to a set of rules that control which Consul resources the token
|
||||
has access to. Policies can be defined in either an allowlist or denylist mode
|
||||
depending on the configuration of
|
||||
[`acl_default_policy`](/docs/agent/config/agent-config-files#acl_default_policy). If the default
|
||||
[`acl_default_policy`](/docs/agent/config/config-files#acl_default_policy). If the default
|
||||
policy is to "deny" all actions, then token rules can be set to allowlist specific
|
||||
actions. In the inverse, the "allow" all default behavior is a denylist where rules
|
||||
are used to prohibit actions. By default, Consul will allow all actions.
|
||||
|
@ -169,7 +169,7 @@ Constructing rules from these policies is covered in detail in the
|
|||
#### ACL Datacenter
|
||||
|
||||
All nodes (clients and servers) must be configured with a
|
||||
[`acl_datacenter`](/docs/agent/config/agent-config-files#acl_datacenter) which enables ACL
|
||||
[`acl_datacenter`](/docs/agent/config/config-files#acl_datacenter) which enables ACL
|
||||
enforcement but also specifies the authoritative datacenter. Consul relies on
|
||||
[RPC forwarding](/docs/internals/architecture) to support multi-datacenter
|
||||
configurations. However, because requests can be made across datacenter boundaries,
|
||||
|
@ -179,14 +179,14 @@ is considered authoritative and stores the canonical set of tokens.
|
|||
When a request is made to an agent in a non-authoritative datacenter, it must be
|
||||
resolved into the appropriate policy. This is done by reading the token from the
|
||||
authoritative server and caching the result for a configurable
|
||||
[`acl_ttl`](/docs/agent/config/agent-config-files#acl_ttl). The implication of caching is that
|
||||
[`acl_ttl`](/docs/agent/config/config-files#acl_ttl). The implication of caching is that
|
||||
the cache TTL is an upper bound on the staleness of policy that is enforced. It is
|
||||
possible to set a zero TTL, but this has adverse performance impacts, as every
|
||||
request requires refreshing the policy via an RPC call.
|
||||
|
||||
During an outage of the ACL datacenter, or loss of connectivity, the cache will be
|
||||
used as long as the TTL is valid, or the cache may be extended if the
|
||||
[`acl_down_policy`](/docs/agent/config/agent-config-files#acl_down_policy) is set accordingly.
|
||||
[`acl_down_policy`](/docs/agent/config/config-files#acl_down_policy) is set accordingly.
|
||||
This configuration also allows the ACL system to fail open or closed.
|
||||
[ACL replication](#replication) is also available to allow for the full set of ACL
|
||||
tokens to be replicated for use during an outage.
|
||||
|
@ -198,10 +198,10 @@ as to whether they are set on servers, clients, or both.
|
|||
|
||||
| Configuration Option | Servers | Clients | Purpose |
|
||||
| --------------------------------------------------------------------- | ---------- | ---------- | ----------------------------------------------------------------------------------------- |
|
||||
| [`acl_datacenter`](/docs/agent/config/agent-config-files#acl_datacenter) | `REQUIRED` | `REQUIRED` | Master control that enables ACLs by defining the authoritative Consul datacenter for ACLs |
|
||||
| [`acl_default_policy`](/docs/agent/config/agent-config-files#acl_default_policy_legacy) | `OPTIONAL` | `N/A` | Determines allowlist or denylist mode |
|
||||
| [`acl_down_policy`](/docs/agent/config/agent-config-files#acl_down_policy_legacy) | `OPTIONAL` | `OPTIONAL` | Determines what to do when the ACL datacenter is offline |
|
||||
| [`acl_ttl`](/docs/agent/config/agent-config-files#acl_ttl_legacy) | `OPTIONAL` | `OPTIONAL` | Determines time-to-live for cached ACLs |
|
||||
| [`acl_datacenter`](/docs/agent/config/config-files#acl_datacenter) | `REQUIRED` | `REQUIRED` | Master control that enables ACLs by defining the authoritative Consul datacenter for ACLs |
|
||||
| [`acl_default_policy`](/docs/agent/config/config-files#acl_default_policy_legacy) | `OPTIONAL` | `N/A` | Determines allowlist or denylist mode |
|
||||
| [`acl_down_policy`](/docs/agent/config/config-files#acl_down_policy_legacy) | `OPTIONAL` | `OPTIONAL` | Determines what to do when the ACL datacenter is offline |
|
||||
| [`acl_ttl`](/docs/agent/config/config-files#acl_ttl_legacy) | `OPTIONAL` | `OPTIONAL` | Determines time-to-live for cached ACLs |
|
||||
|
||||
There are some additional configuration items related to [ACL replication](#replication) and
|
||||
[Version 8 ACL support](#version_8_acls). These are discussed in those respective sections
|
||||
|
@ -212,17 +212,17 @@ system, or accessing Consul in special situations:
|
|||
|
||||
| Special Token | Servers | Clients | Purpose |
|
||||
| ----------------------------------------------------------------------------- | ---------- | ---------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| [`acl_agent_master_token`](/docs/agent/config/agent-config-files#acl_agent_master_token_legacy) | `OPTIONAL` | `OPTIONAL` | Special token that can be used to access [Agent API](/api/agent) when the ACL datacenter isn't available, or servers are offline (for clients); used for setting up the cluster such as doing initial join operations, see the [ACL Agent Master Token](#acl-agent-master-token) section for more details |
|
||||
| [`acl_agent_token`](/docs/agent/config/agent-config-files#acl_agent_token_legacy) | `OPTIONAL` | `OPTIONAL` | Special token that is used for an agent's internal operations, see the [ACL Agent Token](#acl-agent-token) section for more details |
|
||||
| [`acl_master_token`](/docs/agent/config/agent-config-files#acl_master_token_legacy) | `REQUIRED` | `N/A` | Special token used to bootstrap the ACL system, see the [Bootstrapping ACLs](#bootstrapping-acls) section for more details |
|
||||
| [`acl_token`](/docs/agent/config/agent-config-files#acl_token_legacy) | `OPTIONAL` | `OPTIONAL` | Default token to use for client requests where no token is supplied; this is often configured with read-only access to services to enable DNS service discovery on agents |
|
||||
| [`acl_agent_master_token`](/docs/agent/config/config-files#acl_agent_master_token_legacy) | `OPTIONAL` | `OPTIONAL` | Special token that can be used to access [Agent API](/api/agent) when the ACL datacenter isn't available, or servers are offline (for clients); used for setting up the cluster such as doing initial join operations, see the [ACL Agent Master Token](#acl-agent-master-token) section for more details |
|
||||
| [`acl_agent_token`](/docs/agent/config/config-files#acl_agent_token_legacy) | `OPTIONAL` | `OPTIONAL` | Special token that is used for an agent's internal operations, see the [ACL Agent Token](#acl-agent-token) section for more details |
|
||||
| [`acl_master_token`](/docs/agent/config/config-files#acl_master_token_legacy) | `REQUIRED` | `N/A` | Special token used to bootstrap the ACL system, see the [Bootstrapping ACLs](#bootstrapping-acls) section for more details |
|
||||
| [`acl_token`](/docs/agent/config/config-files#acl_token_legacy) | `OPTIONAL` | `OPTIONAL` | Default token to use for client requests where no token is supplied; this is often configured with read-only access to services to enable DNS service discovery on agents |
|
||||
|
||||
In Consul 0.9.1 and later, the agent ACL tokens can be introduced or updated via the
|
||||
[/v1/agent/token API](/api/agent#update-acl-tokens).
|
||||
|
||||
#### ACL Agent Master Token
|
||||
|
||||
Since the [`acl_agent_master_token`](/docs/agent/config/agent-config-files#acl_agent_master_token_legacy) is designed to be used when the Consul servers are not available, its policy is managed locally on the agent and does not need to have a token defined on the Consul servers via the ACL API. Once set, it implicitly has the following policy associated with it (the `node` policy was added in Consul 0.9.0):
|
||||
Since the [`acl_agent_master_token`](/docs/agent/config/config-files#acl_agent_master_token_legacy) is designed to be used when the Consul servers are not available, its policy is managed locally on the agent and does not need to have a token defined on the Consul servers via the ACL API. Once set, it implicitly has the following policy associated with it (the `node` policy was added in Consul 0.9.0):
|
||||
|
||||
```hcl
|
||||
agent "<node name of agent>" {
|
||||
|
@ -238,7 +238,7 @@ In Consul 0.9.1 and later, the agent ACL tokens can be introduced or updated via
|
|||
|
||||
#### ACL Agent Token
|
||||
|
||||
The [`acl_agent_token`](/docs/agent/config/agent-config-files#acl_agent_token) is a special token that is used for an agent's internal operations. It isn't used directly for any user-initiated operations like the [`acl_token`](/docs/agent/config/agent-config-files#acl_token), though if the `acl_agent_token` isn't configured the `acl_token` will be used. The ACL agent token is used for the following operations by the agent:
|
||||
The [`acl_agent_token`](/docs/agent/config/config-files#acl_agent_token) is a special token that is used for an agent's internal operations. It isn't used directly for any user-initiated operations like the [`acl_token`](/docs/agent/config/config-files#acl_token), though if the `acl_agent_token` isn't configured the `acl_token` will be used. The ACL agent token is used for the following operations by the agent:
|
||||
|
||||
1. Updating the agent's node entry using the [Catalog API](/api/catalog), including updating its node metadata, tagged addresses, and network coordinates
|
||||
2. Performing [anti-entropy](/docs/internals/anti-entropy) syncing, in particular reading the node metadata and services registered with the catalog
|
||||
|
@ -258,7 +258,7 @@ key "_rexec" {
|
|||
}
|
||||
```
|
||||
|
||||
The `service` policy needs `read` access for any services that can be registered on the agent. If [remote exec is disabled](/docs/agent/config/agent-config-files#disable_remote_exec), the default, then the `key` policy can be omitted.
|
||||
The `service` policy needs `read` access for any services that can be registered on the agent. If [remote exec is disabled](/docs/agent/config/config-files#disable_remote_exec), the default, then the `key` policy can be omitted.
|
||||
|
||||
In Consul 0.9.1 and later, the agent ACL tokens can be introduced or updated via the
|
||||
[/v1/agent/token API](/api/agent#update-acl-tokens).
|
||||
|
@ -294,12 +294,12 @@ The servers will need to be restarted to load the new configuration. Please take
|
|||
to start the servers one at a time, and ensure each server has joined and is operating
|
||||
correctly before starting another.
|
||||
|
||||
The [`acl_master_token`](/docs/agent/config/agent-config-files#acl_master_token) will be created
|
||||
The [`acl_master_token`](/docs/agent/config/config-files#acl_master_token) will be created
|
||||
as a "management" type token automatically. The
|
||||
[`acl_master_token`](/docs/agent/config/agent-config-files#acl_master_token) is only installed when
|
||||
[`acl_master_token`](/docs/agent/config/config-files#acl_master_token) is only installed when
|
||||
a server acquires cluster leadership. If you would like to install or change the
|
||||
[`acl_master_token`](/docs/agent/config/agent-config-files#acl_master_token), set the new value for
|
||||
[`acl_master_token`](/docs/agent/config/agent-config-files#acl_master_token) in the configuration
|
||||
[`acl_master_token`](/docs/agent/config/config-files#acl_master_token), set the new value for
|
||||
[`acl_master_token`](/docs/agent/config/config-files#acl_master_token) in the configuration
|
||||
for all servers. Once this is done, restart the current leader to force a leader election.
|
||||
|
||||
In Consul 0.9.1 and later, you can use the [/v1/acl/bootstrap API](/api/acl/acl#bootstrap-acls)
|
||||
|
@ -332,7 +332,7 @@ servers related to permission denied errors:
|
|||
```
|
||||
|
||||
These errors are because the agent doesn't yet have a properly configured
|
||||
[`acl_agent_token`](/docs/agent/config/agent-config-files#acl_agent_token) that it can use for its
|
||||
[`acl_agent_token`](/docs/agent/config/config-files#acl_agent_token) that it can use for its
|
||||
own internal operations like updating its node information in the catalog and performing
|
||||
[anti-entropy](/docs/internals/anti-entropy) syncing. We can create a token using the
|
||||
ACL API, and the ACL master token we set in the previous step:
|
||||
|
@ -550,9 +550,9 @@ The next section shows an alternative to the anonymous token.
|
|||
|
||||
#### Set Agent-Specific Default Tokens (Optional)
|
||||
|
||||
An alternative to the anonymous token is the [`acl_token`](/docs/agent/config/agent-config-files#acl_token)
|
||||
An alternative to the anonymous token is the [`acl_token`](/docs/agent/config/config-files#acl_token)
|
||||
configuration item. When a request is made to a particular Consul agent and no token is
|
||||
supplied, the [`acl_token`](/docs/agent/config/agent-config-files#acl_token) will be used for the token,
|
||||
supplied, the [`acl_token`](/docs/agent/config/config-files#acl_token) will be used for the token,
|
||||
instead of being left empty which would normally invoke the anonymous token.
|
||||
|
||||
In Consul 0.9.1 and later, the agent ACL tokens can be introduced or updated via the
|
||||
|
@ -563,7 +563,7 @@ agent, if desired. For example, this allows more fine grained control of what DN
|
|||
given agent can service, or can give the agent read access to some key-value store prefixes by
|
||||
default.
|
||||
|
||||
If using [`acl_token`](/docs/agent/config/agent-config-files#acl_token), then it's likely the anonymous
|
||||
If using [`acl_token`](/docs/agent/config/config-files#acl_token), then it's likely the anonymous
|
||||
token will have a more restrictive policy than shown in the examples here.
|
||||
|
||||
#### Create Tokens for UI Use (Optional)
|
||||
|
@ -727,7 +727,7 @@ starts with "bar".
|
|||
|
||||
Since [Agent API](/api/agent) utility operations may be required before an agent is joined to
|
||||
a cluster, or during an outage of the Consul servers or ACL datacenter, a special token may be
|
||||
configured with [`acl_agent_master_token`](/docs/agent/config/agent-config-files#acl_agent_master_token) to allow
|
||||
configured with [`acl_agent_master_token`](/docs/agent/config/config-files#acl_agent_master_token) to allow
|
||||
write access to these operations even if no ACL resolution capability is available.
|
||||
|
||||
#### Event Rules
|
||||
|
@ -753,7 +753,7 @@ starts with "deploy".
|
|||
The [`consul exec`](/commands/exec) command uses events with the "\_rexec" prefix during
|
||||
operation, so to enable this feature in a Consul environment with ACLs enabled, you will need to
|
||||
give agents a token with access to this event prefix, in addition to configuring
|
||||
[`disable_remote_exec`](/docs/agent/config/agent-config-files#disable_remote_exec) to `false`.
|
||||
[`disable_remote_exec`](/docs/agent/config/config-files#disable_remote_exec) to `false`.
|
||||
|
||||
#### Key/Value Rules
|
||||
|
||||
|
@ -861,13 +861,13 @@ the example above, the rules allow read-only access to any node name with the em
|
|||
read-write access to any node name that starts with "app", and deny all access to any node name that
|
||||
starts with "admin".
|
||||
|
||||
Agents need to be configured with an [`acl_agent_token`](/docs/agent/config/agent-config-files#acl_agent_token)
|
||||
Agents need to be configured with an [`acl_agent_token`](/docs/agent/config/config-files#acl_agent_token)
|
||||
with at least "write" privileges to their own node name in order to register their information with
|
||||
the catalog, such as node metadata and tagged addresses. If this is configured incorrectly, the agent
|
||||
will print an error to the console when it tries to sync its state with the catalog.
|
||||
|
||||
Consul's DNS interface is also affected by restrictions on node rules. If the
|
||||
[`acl_token`](/docs/agent/config/agent-config-files#acl_token) used by the agent does not have "read" access to a
|
||||
[`acl_token`](/docs/agent/config/config-files#acl_token) used by the agent does not have "read" access to a
|
||||
given node, then the DNS interface will return no records when queried for it.
|
||||
|
||||
When reading from the catalog or retrieving information from the health endpoints, node rules are
|
||||
|
@ -880,7 +880,7 @@ periodic [anti-entropy](/docs/internals/anti-entropy) syncs, which may require a
|
|||
ACL token to complete. To accommodate this, Consul provides two methods of configuring ACL tokens
|
||||
to use for registration events:
|
||||
|
||||
1. Using the [acl_token](/docs/agent/config/agent-config-files#acl_token) configuration
|
||||
1. Using the [acl_token](/docs/agent/config/config-files#acl_token) configuration
|
||||
directive. This allows a single token to be configured globally and used
|
||||
during all check registration operations.
|
||||
2. Providing an ACL token with service and check definitions at
|
||||
|
@ -891,7 +891,7 @@ to use for registration events:
|
|||
[HTTP API](/api) for operations that require them.
|
||||
|
||||
In addition to ACLs, in Consul 0.9.0 and later, the agent must be configured with
|
||||
[`enable_script_checks`](/docs/agent/config/agent-config-files#enable_script_checks) set to `true` in order to enable
|
||||
[`enable_script_checks`](/docs/agent/config/config-files#enable_script_checks) set to `true` in order to enable
|
||||
script checks.
|
||||
|
||||
#### Operator Rules
|
||||
|
@ -1025,7 +1025,7 @@ read-write access to any service name that starts with "app", and deny all acces
|
|||
starts with "admin".
|
||||
|
||||
Consul's DNS interface is affected by restrictions on service rules. If the
|
||||
[`acl_token`](/docs/agent/config/agent-config-files#acl_token) used by the agent does not have "read" access to a
|
||||
[`acl_token`](/docs/agent/config/config-files#acl_token) used by the agent does not have "read" access to a
|
||||
given service, then the DNS interface will return no records when queried for it.
|
||||
|
||||
When reading from the catalog or retrieving information from the health endpoints, service rules are
|
||||
|
@ -1037,7 +1037,7 @@ performs periodic [anti-entropy](/docs/internals/anti-entropy) syncs, which may
|
|||
ACL token to complete. To accommodate this, Consul provides two methods of configuring ACL tokens
|
||||
to use for registration events:
|
||||
|
||||
1. Using the [acl_token](/docs/agent/config/agent-config-files#acl_token) configuration
|
||||
1. Using the [acl_token](/docs/agent/config/config-files#acl_token) configuration
|
||||
directive. This allows a single token to be configured globally and used
|
||||
during all service and check registration operations.
|
||||
2. Providing an ACL token with service and check definitions at registration
|
||||
|
@ -1048,12 +1048,12 @@ to use for registration events:
|
|||
API](/api) for operations that require them. **Note:** all tokens
|
||||
passed to an agent are persisted on local disk to allow recovery from
|
||||
restarts. See [`-data-dir` flag
|
||||
documentation](/docs/agent/config/agent-config-files#acl_token) for notes on securing
|
||||
documentation](/docs/agent/config/config-files#acl_token) for notes on securing
|
||||
access.
|
||||
|
||||
In addition to ACLs, in Consul 0.9.0 and later, the agent must be configured with
|
||||
[`enable_script_checks`](/docs/agent/config/agent-config-files#enable_script_checks) or
|
||||
[`enable_local_script_checks`](/docs/agent/config/agent-config-files#enable_local_script_checks)
|
||||
[`enable_script_checks`](/docs/agent/config/config-files#enable_script_checks) or
|
||||
[`enable_local_script_checks`](/docs/agent/config/config-files#enable_local_script_checks)
|
||||
set to `true` in order to enable script checks.
|
||||
|
||||
#### Session Rules
|
||||
|
@ -1084,20 +1084,20 @@ name that starts with "admin".
|
|||
#### Outages and ACL Replication ((#replication))
|
||||
|
||||
The Consul ACL system is designed with flexible rules to accommodate for an outage
|
||||
of the [`acl_datacenter`](/docs/agent/config/agent-config-files#acl_datacenter) or networking
|
||||
of the [`acl_datacenter`](/docs/agent/config/config-files#acl_datacenter) or networking
|
||||
issues preventing access to it. In this case, it may be impossible for
|
||||
agents in non-authoritative datacenters to resolve tokens. Consul provides
|
||||
a number of configurable [`acl_down_policy`](/docs/agent/config/agent-config-files#acl_down_policy)
|
||||
a number of configurable [`acl_down_policy`](/docs/agent/config/config-files#acl_down_policy)
|
||||
choices to tune behavior. It is possible to deny or permit all actions or to ignore
|
||||
cache TTLs and enter a fail-safe mode. The default is to ignore cache TTLs
|
||||
for any previously resolved tokens and to deny any uncached tokens.
|
||||
|
||||
Consul 0.7 added an ACL Replication capability that can allow non-authoritative
|
||||
datacenter agents to resolve even uncached tokens. This is enabled by setting an
|
||||
[`acl_replication_token`](/docs/agent/config/agent-config-files#acl_replication_token) in the
|
||||
[`acl_replication_token`](/docs/agent/config/config-files#acl_replication_token) in the
|
||||
configuration on the servers in the non-authoritative datacenters. In Consul
|
||||
0.9.1 and later you can enable ACL replication using
|
||||
[`enable_acl_replication`](/docs/agent/config/agent-config-files#enable_acl_replication) and
|
||||
[`enable_acl_replication`](/docs/agent/config/config-files#enable_acl_replication) and
|
||||
then set the token later using the
|
||||
[agent token API](/api/agent#update-acl-tokens) on each server. This can
|
||||
also be used to rotate the token without restarting the Consul servers.
|
||||
|
@ -1113,7 +1113,7 @@ every 30 seconds. Replicated changes are written at a rate that's throttled to
|
|||
a large set of ACLs.
|
||||
|
||||
If there's a partition or other outage affecting the authoritative datacenter,
|
||||
and the [`acl_down_policy`](/docs/agent/config/agent-config-files#acl_down_policy)
|
||||
and the [`acl_down_policy`](/docs/agent/config/config-files#acl_down_policy)
|
||||
is set to "extend-cache", tokens will be resolved during the outage using the
|
||||
replicated set of ACLs. An [ACL replication status](/api/acl/acl#check-acl-replication)
|
||||
endpoint is available to monitor the health of the replication process.
|
||||
|
@ -1123,7 +1123,7 @@ already cached and is expired while similar semantics than "extend-cache".
|
|||
It allows to avoid having issues when connectivity with the authoritative is not completely
|
||||
broken, but very slow.
|
||||
|
||||
Locally-resolved ACLs will be cached using the [`acl_ttl`](/docs/agent/config/agent-config-files#acl_ttl)
|
||||
Locally-resolved ACLs will be cached using the [`acl_ttl`](/docs/agent/config/config-files#acl_ttl)
|
||||
setting of the non-authoritative datacenter, so these entries may persist in the
|
||||
cache for up to the TTL, even after the authoritative datacenter comes back online.
|
||||
|
||||
|
@ -1149,7 +1149,7 @@ Consul 0.8 added many more ACL policy types and brought ACL enforcement to Consu
|
|||
agents for the first time. To ease the transition to Consul 0.8 for existing ACL
|
||||
users, there's a configuration option to disable these new features. To disable
|
||||
support for these new ACLs, set the
|
||||
[`acl_enforce_version_8`](/docs/agent/config/agent-config-files#acl_enforce_version_8) configuration
|
||||
[`acl_enforce_version_8`](/docs/agent/config/config-files#acl_enforce_version_8) configuration
|
||||
option to `false` on Consul clients and servers.
|
||||
|
||||
Here's a summary of the new features:
|
||||
|
@ -1172,31 +1172,31 @@ Here's a summary of the new features:
|
|||
|
||||
Two new configuration options are used once version 8 ACLs are enabled:
|
||||
|
||||
- [`acl_agent_master_token`](/docs/agent/config/agent-config-files#acl_agent_master_token) is used as
|
||||
- [`acl_agent_master_token`](/docs/agent/config/config-files#acl_agent_master_token) is used as
|
||||
a special access token that has `agent` ACL policy `write` privileges on each agent where
|
||||
it is configured, as well as `node` ACL policy `read` privileges for all nodes. This token
|
||||
should only be used by operators during outages when Consul servers aren't available to
|
||||
resolve ACL tokens. Applications should use regular ACL tokens during normal operation.
|
||||
- [`acl_agent_token`](/docs/agent/config/agent-config-files#acl_agent_token) is used internally by
|
||||
- [`acl_agent_token`](/docs/agent/config/config-files#acl_agent_token) is used internally by
|
||||
Consul agents to perform operations to the service catalog when registering themselves
|
||||
or sending network coordinates to the servers. This token must at least have `node` ACL
|
||||
policy `write` access to the node name it will register as in order to register any
|
||||
node-level information like metadata or tagged addresses.
|
||||
|
||||
Since clients now resolve ACLs locally, the [`acl_down_policy`](/docs/agent/config/agent-config-files#acl_down_policy)
|
||||
Since clients now resolve ACLs locally, the [`acl_down_policy`](/docs/agent/config/config-files#acl_down_policy)
|
||||
now applies to Consul clients as well as Consul servers. This will determine what the
|
||||
client will do in the event that the servers are down.
|
||||
|
||||
Consul clients must have [`acl_datacenter`](/docs/agent/config/agent-config-files#acl_datacenter) configured
|
||||
Consul clients must have [`acl_datacenter`](/docs/agent/config/config-files#acl_datacenter) configured
|
||||
in order to enable agent-level ACL features. If this is set, the agents will contact the Consul
|
||||
servers to determine if ACLs are enabled at the cluster level. If they detect that ACLs are not
|
||||
enabled, they will check at most every 2 minutes to see if they have become enabled, and will
|
||||
start enforcing ACLs automatically. If an agent has an `acl_datacenter` defined, operators will
|
||||
need to use the [`acl_agent_master_token`](/docs/agent/config/agent-config-files#acl_agent_master_token) to
|
||||
need to use the [`acl_agent_master_token`](/docs/agent/config/config-files#acl_agent_master_token) to
|
||||
perform agent-level operations if the Consul servers aren't present (such as for a manual join
|
||||
to the cluster), unless the [`acl_down_policy`](/docs/agent/config/agent-config-files#acl_down_policy) on the
|
||||
to the cluster), unless the [`acl_down_policy`](/docs/agent/config/config-files#acl_down_policy) on the
|
||||
agent is set to "allow".
|
||||
|
||||
Non-server agents do not need to have the
|
||||
[`acl_master_token`](/docs/agent/config/agent-config-files#acl_master_token) configured; it is not
|
||||
[`acl_master_token`](/docs/agent/config/config-files#acl_master_token) configured; it is not
|
||||
used by agents in any way.
|
||||
|
|
|
@ -102,7 +102,7 @@ Use the `policy` keyword and one of the following access levels to set a policy
|
|||
- `write`: Allows the resource to be read and modified.
|
||||
- `deny`: Denies read and write access to the resource.
|
||||
|
||||
The special `list` access level provices access to all keys with the specified resource label in the Consul KV. The `list` access level can only be used with the `key_prefix` resource. The [`acl.enable_key_list_policy`](/docs/agent/config/agent-config-files#acl_enable_key_list_policy) setting must be set to `true`.
|
||||
The special `list` access level provices access to all keys with the specified resource label in the Consul KV. The `list` access level can only be used with the `key_prefix` resource. The [`acl.enable_key_list_policy`](/docs/agent/config/config-files#acl_enable_key_list_policy) setting must be set to `true`.
|
||||
|
||||
### Matching and Prefix Values
|
||||
|
||||
|
@ -493,7 +493,7 @@ with `bar`.
|
|||
|
||||
Since [Agent API](/api/agent) utility operations may be required before an agent is joined to
|
||||
a cluster, or during an outage of the Consul servers or ACL datacenter, a special token may be
|
||||
configured with [`acl.tokens.agent_recovery`](/docs/agent/config/agent-config-files#acl_tokens_agent_recovery) to allow
|
||||
configured with [`acl.tokens.agent_recovery`](/docs/agent/config/config-files#acl_tokens_agent_recovery) to allow
|
||||
write access to these operations even if no ACL resolution capability is available.
|
||||
|
||||
### Event Rules
|
||||
|
@ -537,7 +537,7 @@ read-only access to any event, and firing of the "deploy" event.
|
|||
The [`consul exec`](/commands/exec) command uses events with the "\_rexec" prefix during
|
||||
operation, so to enable this feature in a Consul environment with ACLs enabled, you will need to
|
||||
give agents a token with access to this event prefix, in addition to configuring
|
||||
[`disable_remote_exec`](/docs/agent/config/agent-config-files#disable_remote_exec) to `false`.
|
||||
[`disable_remote_exec`](/docs/agent/config/config-files#disable_remote_exec) to `false`.
|
||||
|
||||
### Key/Value Rules
|
||||
|
||||
|
@ -869,16 +869,16 @@ node "admin" {
|
|||
|
||||
Agents must be configured with `write` privileges for their own node name so that the agent can register their node metadata, tagged addresses, and other information in the catalog.
|
||||
If configured incorrectly, the agent will print an error to the console when it tries to sync its state with the catalog.
|
||||
Configure `write` access in the [`acl.tokens.agent`](/docs/agent/config/agent-config-files#acl_tokens_agent) parameter.
|
||||
Configure `write` access in the [`acl.tokens.agent`](/docs/agent/config/config-files#acl_tokens_agent) parameter.
|
||||
|
||||
The [`acl.token.default`](/docs/agent/config/agent-config-files#acl_tokens_default) used by the agent should have `read` access to a given node so that the DNS interface can be queried.
|
||||
The [`acl.token.default`](/docs/agent/config/config-files#acl_tokens_default) used by the agent should have `read` access to a given node so that the DNS interface can be queried.
|
||||
|
||||
Node rules are used to filter query results when reading from the catalog or retrieving information from the health endpoints. This allows for configurations where a token has access to a given service name, but only on an allowed subset of node names.
|
||||
|
||||
Consul agents check tokens locally when health checks are registered and when Consul performs periodic [anti-entropy](/docs/internals/anti-entropy) syncs.
|
||||
These actions may required an ACL token to complete. Use the following methods to configure ACL tokens for registration events:
|
||||
|
||||
* Configure a global token in the [acl.tokens.default](/docs/agent/config/agent-config-files#acl_tokens_default) parameter.
|
||||
* Configure a global token in the [acl.tokens.default](/docs/agent/config/config-files#acl_tokens_default) parameter.
|
||||
This allows a single token to be used during all check registration operations.
|
||||
* Provide an ACL token with service and check definitions at registration time.
|
||||
This allows for greater flexibility and enables the use of multiple tokens on the same agent.
|
||||
|
@ -1060,7 +1060,7 @@ service "admin" {
|
|||
</CodeTabs>
|
||||
|
||||
Consul's DNS interface is affected by restrictions on service rules. If the
|
||||
[`acl.tokens.default`](/docs/agent/config/agent-config-files#acl_tokens_default) used by the agent does not have `read` access to a
|
||||
[`acl.tokens.default`](/docs/agent/config/config-files#acl_tokens_default) used by the agent does not have `read` access to a
|
||||
given service, then the DNS interface will return no records when queried for it.
|
||||
|
||||
When reading from the catalog or retrieving information from the health endpoints, service rules are
|
||||
|
@ -1072,7 +1072,7 @@ performs periodic [anti-entropy](/docs/internals/anti-entropy) syncs, which may
|
|||
ACL token to complete. To accommodate this, Consul provides two methods of configuring ACL tokens
|
||||
to use for registration events:
|
||||
|
||||
1. Using the [acl.tokens.default](/docs/agent/config/agent-config-files#acl_tokens_default) configuration
|
||||
1. Using the [acl.tokens.default](/docs/agent/config/config-files#acl_tokens_default) configuration
|
||||
directive. This allows a single token to be configured globally and used
|
||||
during all service and check registration operations.
|
||||
2. Providing an ACL token with service and check definitions at registration
|
||||
|
@ -1083,12 +1083,12 @@ to use for registration events:
|
|||
API](/api) for operations that require them. **Note:** all tokens
|
||||
passed to an agent are persisted on local disk to allow recovery from
|
||||
restarts. See [`-data-dir` flag
|
||||
documentation](/docs/agent/config/agent-config-files#acl_token) for notes on securing
|
||||
documentation](/docs/agent/config/config-files#acl_token) for notes on securing
|
||||
access.
|
||||
|
||||
In addition to ACLs, in Consul 0.9.0 and later, the agent must be configured with
|
||||
[`enable_script_checks`](/docs/agent/config/agent-config-files#enable_script_checks) or
|
||||
[`enable_local_script_checks`](/docs/agent/config/agent-config-files#enable_local_script_checks)
|
||||
[`enable_script_checks`](/docs/agent/config/config-files#enable_script_checks) or
|
||||
[`enable_local_script_checks`](/docs/agent/config/config-files#enable_local_script_checks)
|
||||
set to `true` in order to enable script checks.
|
||||
|
||||
Service rules are also used to grant read or write access to intentions. The
|
||||
|
|
|
@ -51,7 +51,7 @@ may benefit from additional components in the ACL system:
|
|||
|
||||
- **ACL Node Identities** - Node identities are a policy template for
|
||||
expressing a link to a policy suitable for use as an [Consul `agent` token
|
||||
](/docs/agent/config/agent-config-files#acl_tokens_agent). At authorization time this acts like an
|
||||
](/docs/agent/config/config-files#acl_tokens_agent). At authorization time this acts like an
|
||||
additional policy was attached, the contents of which are described further
|
||||
below. These are directly attached to tokens and roles and are not
|
||||
independently configured. (Added in Consul 1.8.1)
|
||||
|
@ -174,7 +174,7 @@ examples of using a service identity.
|
|||
-> Added in Consul 1.8.1
|
||||
|
||||
An ACL node identity is an [ACL policy](/docs/acl/acl-system#acl-policies) template for expressing a link to a policy
|
||||
suitable for use as an [Consul `agent` token](/docs/agent/config/agent-config-files#acl_tokens_agent). They are usable
|
||||
suitable for use as an [Consul `agent` token](/docs/agent/config/config-files#acl_tokens_agent). They are usable
|
||||
on both tokens and roles and are composed of the following elements:
|
||||
|
||||
- **Node Name** - The name of the node to grant access to.
|
||||
|
@ -309,7 +309,7 @@ token will be used.
|
|||
|
||||
The rules from all policies, roles, and service identities linked with a token are combined to form that token's
|
||||
effective rule set. Policy rules can be defined in either an allowlist or denylist
|
||||
mode depending on the configuration of [`acl_default_policy`](/docs/agent/config/agent-config-files#acl_default_policy).
|
||||
mode depending on the configuration of [`acl_default_policy`](/docs/agent/config/config-files#acl_default_policy).
|
||||
If the default policy is to "deny" access to all resources, then policy rules can be set to
|
||||
allowlist access to specific resources. Conversely, if the default policy is “allow” then policy rules can
|
||||
be used to explicitly deny access to resources.
|
||||
|
@ -358,22 +358,22 @@ as to whether they are set on servers, clients, or both.
|
|||
|
||||
| Configuration Option | Servers | Clients | Purpose |
|
||||
| -------------------------------------------------------------- | ---------- | ---------- | ---------------------------------------------------------------------- |
|
||||
| [`acl.enabled`](/docs/agent/config/agent-config-files#acl_enabled) | `REQUIRED` | `REQUIRED` | Controls whether ACLs are enabled |
|
||||
| [`acl.default_policy`](/docs/agent/config/agent-config-files#acl_default_policy) | `OPTIONAL` | `N/A` | Determines allowlist or denylist mode |
|
||||
| [`acl.down_policy`](/docs/agent/config/agent-config-files#acl_down_policy) | `OPTIONAL` | `OPTIONAL` | Determines what to do when the remote token or policy resolution fails |
|
||||
| [`acl.role_ttl`](/docs/agent/config/agent-config-files#acl_role_ttl) | `OPTIONAL` | `OPTIONAL` | Determines time-to-live for cached ACL Roles |
|
||||
| [`acl.policy_ttl`](/docs/agent/config/agent-config-files#acl_policy_ttl) | `OPTIONAL` | `OPTIONAL` | Determines time-to-live for cached ACL Policies |
|
||||
| [`acl.token_ttl`](/docs/agent/config/agent-config-files#acl_token_ttl) | `OPTIONAL` | `OPTIONAL` | Determines time-to-live for cached ACL Tokens |
|
||||
| [`acl.enabled`](/docs/agent/config/config-files#acl_enabled) | `REQUIRED` | `REQUIRED` | Controls whether ACLs are enabled |
|
||||
| [`acl.default_policy`](/docs/agent/config/config-files#acl_default_policy) | `OPTIONAL` | `N/A` | Determines allowlist or denylist mode |
|
||||
| [`acl.down_policy`](/docs/agent/config/config-files#acl_down_policy) | `OPTIONAL` | `OPTIONAL` | Determines what to do when the remote token or policy resolution fails |
|
||||
| [`acl.role_ttl`](/docs/agent/config/config-files#acl_role_ttl) | `OPTIONAL` | `OPTIONAL` | Determines time-to-live for cached ACL Roles |
|
||||
| [`acl.policy_ttl`](/docs/agent/config/config-files#acl_policy_ttl) | `OPTIONAL` | `OPTIONAL` | Determines time-to-live for cached ACL Policies |
|
||||
| [`acl.token_ttl`](/docs/agent/config/config-files#acl_token_ttl) | `OPTIONAL` | `OPTIONAL` | Determines time-to-live for cached ACL Tokens |
|
||||
|
||||
A number of special tokens can also be configured which allow for bootstrapping the ACL
|
||||
system, or accessing Consul in special situations:
|
||||
|
||||
| Special Token | Servers | Clients | Purpose |
|
||||
| ------------------------------------------------------------------------------------ | ---------- | ---------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| [`acl.tokens.agent_recovery`](/docs/agent/config/agent-config-files#acl_tokens_agent_recovery) | `OPTIONAL` | `OPTIONAL` | Special token that can be used to access [Agent API](/api/agent) when remote bearer token resolution fails; used for setting up the cluster such as doing initial join operations, see the [ACL Agent Recovery Token](#acl-agent-recovery-token) section for more details |
|
||||
| [`acl.tokens.agent`](/docs/agent/config/agent-config-files#acl_tokens_agent) | `OPTIONAL` | `OPTIONAL` | Special token that is used for an agent's internal operations, see the [ACL Agent Token](#acl-agent-token) section for more details |
|
||||
| [`acl.tokens.initial_management`](/docs/agent/config/agent-config-files#acl_tokens_initial_management) | `OPTIONAL` | `N/A` | Special token used to bootstrap the ACL system, check the [Bootstrapping ACLs](https://learn.hashicorp.com/tutorials/consul/access-control-setup-production) tutorial for more details |
|
||||
| [`acl.tokens.default`](/docs/agent/config/agent-config-files#acl_tokens_default) | `OPTIONAL` | `OPTIONAL` | Default token to use for client requests where no token is supplied; this is often configured with read-only access to services to enable DNS service discovery on agents |
|
||||
| [`acl.tokens.agent_recovery`](/docs/agent/config/config-files#acl_tokens_agent_recovery) | `OPTIONAL` | `OPTIONAL` | Special token that can be used to access [Agent API](/api/agent) when remote bearer token resolution fails; used for setting up the cluster such as doing initial join operations, see the [ACL Agent Recovery Token](#acl-agent-recovery-token) section for more details |
|
||||
| [`acl.tokens.agent`](/docs/agent/config/config-files#acl_tokens_agent) | `OPTIONAL` | `OPTIONAL` | Special token that is used for an agent's internal operations, see the [ACL Agent Token](#acl-agent-token) section for more details |
|
||||
| [`acl.tokens.initial_management`](/docs/agent/config/config-files#acl_tokens_initial_management) | `OPTIONAL` | `N/A` | Special token used to bootstrap the ACL system, check the [Bootstrapping ACLs](https://learn.hashicorp.com/tutorials/consul/access-control-setup-production) tutorial for more details |
|
||||
| [`acl.tokens.default`](/docs/agent/config/config-files#acl_tokens_default) | `OPTIONAL` | `OPTIONAL` | Default token to use for client requests where no token is supplied; this is often configured with read-only access to services to enable DNS service discovery on agents |
|
||||
|
||||
All of these tokens except the `initial_management` token can all be introduced or updated via the [/v1/agent/token API](/api/agent#update-acl-tokens).
|
||||
|
||||
|
@ -381,12 +381,12 @@ In Consul 1.4 - 1.10, the following special tokens were known by different names
|
|||
|
||||
| New Name (1.11+) | Old Name (1.4 - 1.10) |
|
||||
| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------ |
|
||||
| [`acl.tokens.agent_recovery`](/docs/agent/config/agent-config-files#acl_tokens_agent_recovery) | [`acl.tokens.agent_master`](/docs/agent/config/agent-config-files#acl_tokens_agent_master) |
|
||||
| [`acl.tokens.initial_management`](/docs/agent/config/agent-config-files#acl_tokens_initial_management) | [`acl.tokens.master`](/docs/agent/config/agent-config-files#acl_tokens_master) |
|
||||
| [`acl.tokens.agent_recovery`](/docs/agent/config/config-files#acl_tokens_agent_recovery) | [`acl.tokens.agent_master`](/docs/agent/config/config-files#acl_tokens_agent_master) |
|
||||
| [`acl.tokens.initial_management`](/docs/agent/config/config-files#acl_tokens_initial_management) | [`acl.tokens.master`](/docs/agent/config/config-files#acl_tokens_master) |
|
||||
|
||||
#### ACL Agent Recovery Token
|
||||
|
||||
Since the [`acl.tokens.agent_recovery`](/docs/agent/config/agent-config-files#acl_tokens_agent_recovery) is designed to be used when the Consul servers are not available, its policy is managed locally on the agent and does not need to have a token defined on the Consul servers via the ACL API. Once set, it implicitly has the following policy associated with it
|
||||
Since the [`acl.tokens.agent_recovery`](/docs/agent/config/config-files#acl_tokens_agent_recovery) is designed to be used when the Consul servers are not available, its policy is managed locally on the agent and does not need to have a token defined on the Consul servers via the ACL API. Once set, it implicitly has the following policy associated with it
|
||||
|
||||
In Consul 1.4 - 1.10, this was called the `agent_master` token. It was renamed to `agent_recovery` token in Consul 1.11.
|
||||
|
||||
|
@ -401,7 +401,7 @@ node_prefix "" {
|
|||
|
||||
#### ACL Agent Token
|
||||
|
||||
The [`acl.tokens.agent`](/docs/agent/config/agent-config-files#acl_tokens_agent) is a special token that is used for an agent's internal operations. It isn't used directly for any user-initiated operations like the [`acl.tokens.default`](/docs/agent/config/agent-config-files#acl_tokens_default), though if the `acl.tokens.agent` isn't configured the `acl.tokens.default` will be used. The ACL agent token is used for the following operations by the agent:
|
||||
The [`acl.tokens.agent`](/docs/agent/config/config-files#acl_tokens_agent) is a special token that is used for an agent's internal operations. It isn't used directly for any user-initiated operations like the [`acl.tokens.default`](/docs/agent/config/config-files#acl_tokens_default), though if the `acl.tokens.agent` isn't configured the `acl.tokens.default` will be used. The ACL agent token is used for the following operations by the agent:
|
||||
|
||||
1. Updating the agent's node entry using the [Catalog API](/api/catalog), including updating its node metadata, tagged addresses, and network coordinates
|
||||
2. Performing [anti-entropy](/docs/internals/anti-entropy) syncing, in particular reading the node metadata and services registered with the catalog
|
||||
|
@ -421,7 +421,7 @@ key_prefix "_rexec" {
|
|||
}
|
||||
```
|
||||
|
||||
The `service_prefix` policy needs read access for any services that can be registered on the agent. If [remote exec is disabled](/docs/agent/config/agent-config-files#disable_remote_exec), the default, then the `key_prefix` policy can be omitted.
|
||||
The `service_prefix` policy needs read access for any services that can be registered on the agent. If [remote exec is disabled](/docs/agent/config/config-files#disable_remote_exec), the default, then the `key_prefix` policy can be omitted.
|
||||
|
||||
## Next Steps
|
||||
|
||||
|
|
|
@ -60,7 +60,7 @@ using the API or command line before they can be used by applications.
|
|||
endpoints](/api/acl/binding-rules).
|
||||
|
||||
-> **Note** - To configure auth methods in any connected secondary datacenter,
|
||||
[ACL token replication](/docs/agent/config/agent-config-files#acl_enable_token_replication)
|
||||
[ACL token replication](/docs/agent/config/config-files#acl_enable_token_replication)
|
||||
must be enabled. Auth methods require the ability to create local tokens which
|
||||
is restricted to the primary datacenter and any secondary datacenters with ACL
|
||||
token replication enabled.
|
||||
|
|
|
@ -75,17 +75,17 @@ CA then signs keys for each of the agents, as in
|
|||
~> Certificates need to be created with x509v3 extendedKeyUsage attributes for both clientAuth and serverAuth since Consul uses a single cert/key pair for both server and client communications.
|
||||
|
||||
TLS can be used to verify the authenticity of the servers or verify the authenticity of clients.
|
||||
These modes are controlled by the [`verify_outgoing`](/docs/agent/config/agent-config-files#verify_outgoing),
|
||||
[`verify_server_hostname`](/docs/agent/config/agent-config-files#verify_server_hostname),
|
||||
and [`verify_incoming`](/docs/agent/config/agent-config-files#verify_incoming) options, respectively.
|
||||
These modes are controlled by the [`verify_outgoing`](/docs/agent/config/config-files#verify_outgoing),
|
||||
[`verify_server_hostname`](/docs/agent/config/config-files#verify_server_hostname),
|
||||
and [`verify_incoming`](/docs/agent/config/config-files#verify_incoming) options, respectively.
|
||||
|
||||
If [`verify_outgoing`](/docs/agent/config/agent-config-files#verify_outgoing) is set, agents verify the
|
||||
If [`verify_outgoing`](/docs/agent/config/config-files#verify_outgoing) is set, agents verify the
|
||||
authenticity of Consul for outgoing connections. Server nodes must present a certificate signed
|
||||
by a common certificate authority present on all agents, set via the agent's
|
||||
[`ca_file`](/docs/agent/config/agent-config-files#ca_file) and [`ca_path`](/docs/agent/config/agent-config-files#ca_path)
|
||||
options. All server nodes must have an appropriate key pair set using [`cert_file`](/docs/agent/config/agent-config-files#cert_file) and [`key_file`](/docs/agent/config/agent-config-files#key_file).
|
||||
[`ca_file`](/docs/agent/config/config-files#ca_file) and [`ca_path`](/docs/agent/config/config-files#ca_path)
|
||||
options. All server nodes must have an appropriate key pair set using [`cert_file`](/docs/agent/config/config-files#cert_file) and [`key_file`](/docs/agent/config/config-files#key_file).
|
||||
|
||||
If [`verify_server_hostname`](/docs/agent/config/agent-config-files#verify_server_hostname) is set, then
|
||||
If [`verify_server_hostname`](/docs/agent/config/config-files#verify_server_hostname) is set, then
|
||||
outgoing connections perform hostname verification. All servers must have a certificate
|
||||
valid for `server.<datacenter>.<domain>` or the client will reject the handshake. This is
|
||||
a new configuration as of 0.5.1, and it is used to prevent a compromised client from being
|
||||
|
@ -93,12 +93,12 @@ able to restart in server mode and perform a MITM (Man-In-The-Middle) attack. Ne
|
|||
to true, and generate the proper certificates, but this is defaulted to false to avoid breaking
|
||||
existing deployments.
|
||||
|
||||
If [`verify_incoming`](/docs/agent/config/agent-config-files#verify_incoming) is set, the servers verify the
|
||||
If [`verify_incoming`](/docs/agent/config/config-files#verify_incoming) is set, the servers verify the
|
||||
authenticity of all incoming connections. All clients must have a valid key pair set using
|
||||
[`cert_file`](/docs/agent/config/agent-config-files#cert_file) and
|
||||
[`key_file`](/docs/agent/config/agent-config-files#key_file). Servers will
|
||||
[`cert_file`](/docs/agent/config/config-files#cert_file) and
|
||||
[`key_file`](/docs/agent/config/config-files#key_file). Servers will
|
||||
also disallow any non-TLS connections. To force clients to use TLS,
|
||||
[`verify_outgoing`](/docs/agent/config/agent-config-files#verify_outgoing) must also be set.
|
||||
[`verify_outgoing`](/docs/agent/config/config-files#verify_outgoing) must also be set.
|
||||
|
||||
TLS is used to secure the RPC calls between agents, but gossip between nodes is done over UDP
|
||||
and is secured using a symmetric key. See above for enabling gossip encryption.
|
||||
|
|
|
@ -72,28 +72,28 @@ environment and adapt these configurations accordingly.
|
|||
- **mTLS** - Mutual authentication of both the TLS server and client x509 certificates prevents internal abuse through
|
||||
unauthorized access to Consul agents within the cluster.
|
||||
|
||||
- [`verify_incoming`](/docs/agent/config/agent-config-files#verify_incoming) - By default this is false, and should almost always be set
|
||||
- [`verify_incoming`](/docs/agent/config/config-files#verify_incoming) - By default this is false, and should almost always be set
|
||||
to true to require TLS verification for incoming client connections. This applies to both server RPC and to the
|
||||
HTTPS API.
|
||||
|
||||
- [`verify_incoming_https`](/docs/agent/config/agent-config-files#verify_incoming_https) - By default this is false, and should be set
|
||||
- [`verify_incoming_https`](/docs/agent/config/config-files#verify_incoming_https) - By default this is false, and should be set
|
||||
to true to require clients to provide a valid TLS certificate when the Consul HTTPS API is enabled. TLS for the API
|
||||
may be not be necessary if it is exclusively served over a loopback interface such as `localhost`.
|
||||
|
||||
- [`verify_incoming_rpc`](/docs/agent/config/agent-config-files#verify_incoming_rpc) - By default this is false, and should almost
|
||||
- [`verify_incoming_rpc`](/docs/agent/config/config-files#verify_incoming_rpc) - By default this is false, and should almost
|
||||
always be set to true to require clients to provide a valid TLS certificate for Consul agent RPCs.
|
||||
|
||||
- [`verify_outgoing`](/docs/agent/config/agent-config-files#verify_outgoing) - By default this is false, and should be set to true to
|
||||
- [`verify_outgoing`](/docs/agent/config/config-files#verify_outgoing) - By default this is false, and should be set to true to
|
||||
require TLS for outgoing connections from server or client agents. Servers that specify `verify_outgoing = true`
|
||||
will always talk to other servers over TLS, but they still accept non-TLS connections to allow for a transition of
|
||||
all clients to TLS. Currently the only way to enforce that no client can communicate with a server unencrypted is
|
||||
to also enable `verify_incoming` which requires client certificates too.
|
||||
|
||||
- [`enable_agent_tls_for_checks`](/docs/agent/config/agent-config-files#enable_agent_tls_for_checks) - By default this is false, and
|
||||
- [`enable_agent_tls_for_checks`](/docs/agent/config/config-files#enable_agent_tls_for_checks) - By default this is false, and
|
||||
should almost always be set to true to require mTLS to set up the client for HTTP or gRPC health checks. This was
|
||||
added in Consul 1.0.1.
|
||||
|
||||
- [`verify_server_hostname`](/docs/agent/config/agent-config-files#verify_server_hostname) - By default this is false, and should be
|
||||
- [`verify_server_hostname`](/docs/agent/config/config-files#verify_server_hostname) - By default this is false, and should be
|
||||
set to true to require that the TLS certificate presented by the servers matches
|
||||
`server.<datacenter>.<domain>` hostname for outgoing TLS connections. The default configuration does not verify the
|
||||
hostname of the certificate, only that it is signed by a trusted CA. This setting is critical to prevent a
|
||||
|
@ -104,14 +104,14 @@ environment and adapt these configurations accordingly.
|
|||
[CVE-2018-19653](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-19653) for more details. This is fixed
|
||||
in 1.4.1.
|
||||
|
||||
- [`auto_encrypt`](/docs/agent/config/agent-config-files#auto_encrypt) - Enables automated TLS certificate distribution for client
|
||||
agent RPC communication using the Connect CA. Using this configuration a [`ca_file`](/docs/agent/config/agent-config-files#ca_file)
|
||||
- [`auto_encrypt`](/docs/agent/config/config-files#auto_encrypt) - Enables automated TLS certificate distribution for client
|
||||
agent RPC communication using the Connect CA. Using this configuration a [`ca_file`](/docs/agent/config/config-files#ca_file)
|
||||
and ACL token would still need to be distributed to client agents.
|
||||
|
||||
- [`allow_tls`](/docs/agent/config/agent-config-files#allow_tls) - By default this is false, and should be set to true on server
|
||||
- [`allow_tls`](/docs/agent/config/config-files#allow_tls) - By default this is false, and should be set to true on server
|
||||
agents to allow certificates to be automatically generated and distributed from the Connect CA to client agents.
|
||||
|
||||
- [`tls`](/docs/agent/config/agent-config-files#tls) - By default this is false, and should be set to true on client agents to
|
||||
- [`tls`](/docs/agent/config/config-files#tls) - By default this is false, and should be set to true on client agents to
|
||||
automatically request a client TLS certificate from the server's Connect CA.
|
||||
|
||||
**Example Server Agent TLS Configuration**
|
||||
|
@ -144,7 +144,7 @@ environment and adapt these configurations accordingly.
|
|||
}
|
||||
```
|
||||
|
||||
-> The client agent TLS configuration from above sets [`verify_incoming`](/docs/agent/config/agent-config-files#verify_incoming) to
|
||||
-> The client agent TLS configuration from above sets [`verify_incoming`](/docs/agent/config/config-files#verify_incoming) to
|
||||
false which assumes all incoming traffic is restricted to `localhost`. The primary benefit for this configuration
|
||||
would be to avoid provisioning client TLS certificates (in addition to ACL tokens) for all tools or applications
|
||||
using the local Consul agent. In this case ACLs should be enabled to provide authorization and only ACL tokens would
|
||||
|
@ -152,7 +152,7 @@ environment and adapt these configurations accordingly.
|
|||
|
||||
- **ACLs** - The access control list (ACL) system provides a security mechanism for Consul administrators to grant
|
||||
capabilities tied to an individual human, or machine operator identity. To ultimately secure the ACL system,
|
||||
administrators should configure the [`default_policy`](/docs/agent/config/agent-config-files#acl_default_policy) to "deny".
|
||||
administrators should configure the [`default_policy`](/docs/agent/config/config-files#acl_default_policy) to "deny".
|
||||
|
||||
The [system](/docs/acl/acl-system) is comprised of five major components:
|
||||
|
||||
|
@ -179,10 +179,10 @@ environment and adapt these configurations accordingly.
|
|||
Two optional gossip encryption options enable Consul servers without gossip encryption to safely upgrade. After
|
||||
upgrading, the verification options should be enabled, or removed to set them to their default state:
|
||||
|
||||
- [`encrypt_verify_incoming`](/docs/agent/config/agent-config-files#encrypt_verify_incoming) - By default this is true to enforce
|
||||
- [`encrypt_verify_incoming`](/docs/agent/config/config-files#encrypt_verify_incoming) - By default this is true to enforce
|
||||
encryption on _incoming_ gossip communications.
|
||||
|
||||
- [`encrypt_verify_outgoing`](/docs/agent/config/agent-config-files#encrypt_verify_outgoing) - By default this is true to enforce
|
||||
- [`encrypt_verify_outgoing`](/docs/agent/config/config-files#encrypt_verify_outgoing) - By default this is true to enforce
|
||||
encryption on _outgoing_ gossip communications.
|
||||
|
||||
- **Namespaces** <EnterpriseAlert inline /> - Read and write operations should be scoped to logical namespaces to
|
||||
|
@ -223,19 +223,19 @@ environment and adapt these configurations accordingly.
|
|||
- **Linux Security Modules** - Use of security modules that can be directly integrated into operating systems such as
|
||||
AppArmor, SElinux, and Seccomp on Consul agent hosts.
|
||||
|
||||
- **Customize TLS Settings** - TLS settings such as the [available cipher suites](/docs/agent/config/agent-config-files#tls_cipher_suites),
|
||||
- **Customize TLS Settings** - TLS settings such as the [available cipher suites](/docs/agent/config/config-files#tls_cipher_suites),
|
||||
should be tuned to fit the needs of your environment.
|
||||
|
||||
- [`tls_min_version`](/docs/agent/config/agent-config-files#tls_min_version) - Used to specify the minimum TLS version to use.
|
||||
- [`tls_min_version`](/docs/agent/config/config-files#tls_min_version) - Used to specify the minimum TLS version to use.
|
||||
|
||||
- [`tls_cipher_suites`](/docs/agent/config/agent-config-files#tls_cipher_suites) - Used to specify which TLS cipher suites are allowed.
|
||||
- [`tls_cipher_suites`](/docs/agent/config/config-files#tls_cipher_suites) - Used to specify which TLS cipher suites are allowed.
|
||||
|
||||
- [`tls_prefer_server_cipher_suites`](/docs/agent/config/agent-config-files#tls_prefer_server_cipher_suites) - Used to specify which TLS
|
||||
- [`tls_prefer_server_cipher_suites`](/docs/agent/config/config-files#tls_prefer_server_cipher_suites) - Used to specify which TLS
|
||||
cipher suites are preferred on the server side.
|
||||
|
||||
- **Customize HTTP Response Headers** - Additional security headers, such as
|
||||
[`X-XSS-Protection`](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-XSS-Protection), can be
|
||||
[configured](https://www.consul.io/docs/agent/config/agent-config-files#response_headers) for HTTP API responses.
|
||||
[configured](https://www.consul.io/docs/agent/config/config-files#response_headers) for HTTP API responses.
|
||||
|
||||
```hcl
|
||||
http_config {
|
||||
|
@ -248,28 +248,28 @@ environment and adapt these configurations accordingly.
|
|||
- **Customize Default Limits** - Consul has a number of builtin features with default connection limits that should be
|
||||
tuned to fit your environment.
|
||||
|
||||
- [`http_max_conns_per_client`](/docs/agent/config/agent-config-files#http_max_conns_per_client) - Used to limit concurrent access from
|
||||
- [`http_max_conns_per_client`](/docs/agent/config/config-files#http_max_conns_per_client) - Used to limit concurrent access from
|
||||
a single client to the HTTP(S) endpoint on Consul agents.
|
||||
|
||||
- [`https_handshake_timeout`](/docs/agent/config/agent-config-files#https_handshake_timeout) - Used to timeout TLS connection for the
|
||||
- [`https_handshake_timeout`](/docs/agent/config/config-files#https_handshake_timeout) - Used to timeout TLS connection for the
|
||||
HTTP(S) endpoint for Consul agents.
|
||||
|
||||
- [`rpc_handshake_timeout`](/docs/agent/config/agent-config-files#rpc_handshake_timeout) - Used to timeout TLS connections for the RPC
|
||||
- [`rpc_handshake_timeout`](/docs/agent/config/config-files#rpc_handshake_timeout) - Used to timeout TLS connections for the RPC
|
||||
endpoint for Consul agents.
|
||||
|
||||
- [`rpc_max_conns_per_client`](/docs/agent/config/agent-config-files#rpc_max_conns_per_client) - Used to limit concurrent access from a
|
||||
- [`rpc_max_conns_per_client`](/docs/agent/config/config-files#rpc_max_conns_per_client) - Used to limit concurrent access from a
|
||||
single client to the RPC endpoint on Consul agents.
|
||||
|
||||
- [`rpc_rate`](/docs/agent/config/agent-config-files#rpc_rate) - Disabled by default, this is used to limit (requests/second) for client
|
||||
- [`rpc_rate`](/docs/agent/config/config-files#rpc_rate) - Disabled by default, this is used to limit (requests/second) for client
|
||||
agents making RPC calls to server agents.
|
||||
|
||||
- [`rpc_max_burst`](/docs/agent/config/agent-config-files#rpc_max_burst) - Used as the token bucket size for client agents making RPC
|
||||
- [`rpc_max_burst`](/docs/agent/config/config-files#rpc_max_burst) - Used as the token bucket size for client agents making RPC
|
||||
calls to server agents.
|
||||
|
||||
- [`kv_max_value_size`](/docs/agent/config/agent-config-files#kv_max_value_size) - Used to configure the max number of bytes in a
|
||||
- [`kv_max_value_size`](/docs/agent/config/config-files#kv_max_value_size) - Used to configure the max number of bytes in a
|
||||
key-value API request.
|
||||
|
||||
- [`txn_max_req_len`](/docs/agent/config/agent-config-files#txn_max_req_len) - Used to configure the max number of bytes in a
|
||||
- [`txn_max_req_len`](/docs/agent/config/config-files#txn_max_req_len) - Used to configure the max number of bytes in a
|
||||
transaction API request.
|
||||
|
||||
- **Secure UI Access** - Access to Consul’s builtin UI can be secured in various ways:
|
||||
|
@ -289,7 +289,7 @@ environment and adapt these configurations accordingly.
|
|||
[Securing Consul with Access Control Lists (ACLs)](https://learn.hashicorp.com/tutorials/consul/access-control-setup-production),
|
||||
which includes a section on [creating ACL tokens that provide a desired level UI access](https://learn.hashicorp.com/tutorials/consul/access-control-setup-production#consul-ui-token).
|
||||
|
||||
- **Restrict HTTP Writes** - Using the [`allow_write_http_from`](/docs/agent/config/agent-config-files#allow_write_http_from)
|
||||
- **Restrict HTTP Writes** - Using the [`allow_write_http_from`](/docs/agent/config/config-files#allow_write_http_from)
|
||||
configuration option to restrict write access for agent endpoints to hosts on the specified list of CIDRs.
|
||||
|
||||
**Example Agent Configuration**
|
||||
|
|
|
@ -198,14 +198,14 @@ We recommend raising an issue with the CNI you're using to add support for `host
|
|||
and switching back to `hostPort` eventually.
|
||||
|
||||
[troubleshooting]: https://learn.hashicorp.com/consul/day-2-operations/advanced-operations/troubleshooting
|
||||
[node_name]: /docs/agent/config/agent-config-files#node_name
|
||||
[retry_join]: /docs/agent/config/agent-config-cli#retry-join
|
||||
[node_name]: /docs/agent/config/config-files#node_name
|
||||
[retry_join]: /docs/agent/config/cli-flags#retry-join
|
||||
[license]: /commands/license
|
||||
[releases]: https://releases.hashicorp.com/consul/
|
||||
[files]: https://easyengine.io/tutorials/linux/increase-open-files-limit
|
||||
[certificates]: https://learn.hashicorp.com/consul/advanced/day-1-operations/certificates
|
||||
[systemd]: https://learn.hashicorp.com/consul/advanced/day-1-operations/deployment-guide#configure-systemd
|
||||
[monitoring]: https://learn.hashicorp.com/consul/advanced/day-1-operations/monitoring
|
||||
[bind]: /docs/agent/config/agent-config-cli#_bind
|
||||
[bind]: /docs/agent/config/cli-flags#_bind
|
||||
[jq]: https://stedolan.github.io/jq/
|
||||
[go-sockaddr]: https://godoc.org/github.com/hashicorp/go-sockaddr/template
|
||||
|
|
|
@ -62,8 +62,8 @@ messages.
|
|||
This anonymous ID can be disabled. In fact, using the Checkpoint service is
|
||||
optional and can be disabled.
|
||||
|
||||
See [`disable_anonymous_signature`](/docs/agent/config/agent-config-files#disable_anonymous_signature)
|
||||
and [`disable_update_check`](/docs/agent/config/agent-config-files#disable_update_check).
|
||||
See [`disable_anonymous_signature`](/docs/agent/config/config-files#disable_anonymous_signature)
|
||||
and [`disable_update_check`](/docs/agent/config/config-files#disable_update_check).
|
||||
|
||||
### Q: Does Consul rely on UDP Broadcast or Multicast?
|
||||
|
||||
|
@ -116,7 +116,7 @@ as well as race conditions between data updates and watch registrations.
|
|||
|
||||
### Q: What network ports does Consul use?
|
||||
|
||||
The [Ports Used](/docs/agent/config/agent-config-files#ports) section of the Configuration
|
||||
The [Ports Used](/docs/agent/config/config-files#ports) section of the Configuration
|
||||
documentation lists all ports that Consul uses.
|
||||
|
||||
### Q: Does Consul require certain user process resource limits?
|
||||
|
@ -143,7 +143,7 @@ of any excessive resource utilization before arbitrarily increasing the limits.
|
|||
The default recommended limit on a key's value size is 512KB. This is strictly
|
||||
enforced and an HTTP 413 status will be returned to any client that attempts to
|
||||
store more than that limit in a value. The limit can be increased by using the
|
||||
[`kv_max_value_size`](/docs/agent/config/agent-config-files#kv_max_value_size) configuration option.
|
||||
[`kv_max_value_size`](/docs/agent/config/config-files#kv_max_value_size) configuration option.
|
||||
|
||||
It should be noted that the Consul key/value store is not designed to be used as
|
||||
a general purpose database. See
|
||||
|
|
|
@ -74,7 +74,7 @@ this snapshot somewhere safe. More documentation on snapshot usage is available
|
|||
- https://www.consul.io/commands/snapshot
|
||||
- https://learn.hashicorp.com/tutorials/consul/backup-and-restore
|
||||
|
||||
**2.** Temporarily modify your Consul configuration so that its [log_level](/docs/agent/config/agent-config-cli#_log_level)
|
||||
**2.** Temporarily modify your Consul configuration so that its [log_level](/docs/agent/config/cli-flags#_log_level)
|
||||
is set to `debug`. After doing this, issue the following command on your servers to
|
||||
reload the configuration:
|
||||
|
||||
|
@ -183,7 +183,7 @@ then the following options for further assistance are available:
|
|||
When contacting Hashicorp Support, please include the following information in your ticket:
|
||||
|
||||
- Consul version you were upgrading FROM and TO.
|
||||
- [Debug level logs](/docs/agent/config/agent-config-cli#_log_level) from all servers in the cluster
|
||||
- [Debug level logs](/docs/agent/config/cli-flags#_log_level) from all servers in the cluster
|
||||
that you are having trouble with. These should include logs from prior to the upgrade attempt
|
||||
up through the current time. If your logs were not set at debug level prior to the
|
||||
upgrade, please include those logs as well. Also, update your config to use debug logs,
|
||||
|
|
|
@ -51,7 +51,7 @@ Looking through these changes prior to upgrading is highly recommended.
|
|||
Two very notable items are:
|
||||
|
||||
- 1.6.2 introduced more strict JSON decoding. Invalid JSON that was previously ignored might result in errors now (e.g., `Connect: null` in service definitions). See [[GH#6680](https://github.com/hashicorp/consul/pull/6680)].
|
||||
- 1.6.3 introduced the [http_max_conns_per_client](https://www.consul.io/docs/agent/config/agent-config-files.html#http_max_conns_per_client) limit. This defaults to 200. Prior to this, connections per client were unbounded. [[GH#7159](https://github.com/hashicorp/consul/issues/7159)]
|
||||
- 1.6.3 introduced the [http_max_conns_per_client](https://www.consul.io/docs/agent/config/config-files.html#http_max_conns_per_client) limit. This defaults to 200. Prior to this, connections per client were unbounded. [[GH#7159](https://github.com/hashicorp/consul/issues/7159)]
|
||||
|
||||
## Procedure
|
||||
|
||||
|
@ -202,8 +202,8 @@ update those now to avoid issues when moving to newer versions.
|
|||
|
||||
These are the changes you will need to make:
|
||||
|
||||
- `acl_datacenter` is now named `primary_datacenter` (review our [docs](https://www.consul.io/docs/agent/config/agent-config-files#primary_datacenter) for more info)
|
||||
- `acl_default_policy`, `acl_down_policy`, `acl_ttl`, `acl_*_token` and `enable_acl_replication` options are now specified like this (review our [docs](https://www.consul.io/docs/agent/config/agent-config-files#acl) for more info):
|
||||
- `acl_datacenter` is now named `primary_datacenter` (review our [docs](https://www.consul.io/docs/agent/config/config-files#primary_datacenter) for more info)
|
||||
- `acl_default_policy`, `acl_down_policy`, `acl_ttl`, `acl_*_token` and `enable_acl_replication` options are now specified like this (review our [docs](https://www.consul.io/docs/agent/config/config-files#acl) for more info):
|
||||
```hcl
|
||||
acl {
|
||||
enabled = true/false
|
||||
|
|
|
@ -42,7 +42,7 @@ Due to this rename the following endpoint is also deprecated:
|
|||
These config keys are now deprecated:
|
||||
|
||||
- `audit.sink[].name`
|
||||
- [`dns_config.dns_prefer_namespace`](/docs/agent/config/agent-config-files#dns_prefer_namespace)
|
||||
- [`dns_config.dns_prefer_namespace`](/docs/agent/config/config-files#dns_prefer_namespace)
|
||||
|
||||
### Deprecated CLI Subcommands
|
||||
|
||||
|
@ -107,8 +107,8 @@ have a license loaded from a configuration file or from their environment the sa
|
|||
agents must have the license specified. Both agents can still perform automatic retrieval of their
|
||||
license but with a few extra stipulations. First, license auto-retrieval now requires that ACLs
|
||||
are on and that the client or snapshot agent is configured with a valid ACL token. Secondly, client
|
||||
agents require that either the [`start_join`](/docs/agent/config/agent-config-files#start_join) or
|
||||
[`retry_join`](/docs/agent/config/agent-config-files#retry_join) configurations are set and that they resolve to server
|
||||
agents require that either the [`start_join`](/docs/agent/config/config-files#start_join) or
|
||||
[`retry_join`](/docs/agent/config/config-files#retry_join) configurations are set and that they resolve to server
|
||||
agents. If those stipulations are not met, attempting to start the client or snapshot agent will
|
||||
result in it immediately shutting down.
|
||||
|
||||
|
@ -202,7 +202,7 @@ to Consul 1.9.0.
|
|||
|
||||
### Changes to Configuration Defaults
|
||||
|
||||
The [`enable_central_service_config`](/docs/agent/config/agent-config-files#enable_central_service_config)
|
||||
The [`enable_central_service_config`](/docs/agent/config/config-files#enable_central_service_config)
|
||||
configuration now defaults to `true`.
|
||||
|
||||
### Changes to Intentions
|
||||
|
@ -271,7 +271,7 @@ behavior:
|
|||
|
||||
#### Removal of Deprecated Features
|
||||
|
||||
The [`acl_enforce_version_8`](/docs/agent/config/agent-config-files#acl_enforce_version_8)
|
||||
The [`acl_enforce_version_8`](/docs/agent/config/config-files#acl_enforce_version_8)
|
||||
configuration has been removed (with version 8 ACL support by being on by
|
||||
default).
|
||||
|
||||
|
@ -314,7 +314,7 @@ to more precisely capture the view of _active_ blocking queries.
|
|||
|
||||
### Vault: default `http_max_conns_per_client` too low to run Vault properly
|
||||
|
||||
Consul 1.7.0 introduced [limiting of connections per client](/docs/agent/config/agent-config-files#http_max_conns_per_client). The default value
|
||||
Consul 1.7.0 introduced [limiting of connections per client](/docs/agent/config/config-files#http_max_conns_per_client). The default value
|
||||
was 100, but Vault could use up to 128, which caused problems. If you want to use Vault with Consul 1.7.0, you should change the value to 200.
|
||||
Starting with Consul 1.7.1 this is the new default.
|
||||
|
||||
|
@ -322,7 +322,7 @@ Starting with Consul 1.7.1 this is the new default.
|
|||
|
||||
### Vault: default `http_max_conns_per_client` too low to run Vault properly
|
||||
|
||||
Consul 1.6.3 introduced [limiting of connections per client](/docs/agent/config/agent-config-files#http_max_conns_per_client). The default value
|
||||
Consul 1.6.3 introduced [limiting of connections per client](/docs/agent/config/config-files#http_max_conns_per_client). The default value
|
||||
was 100, but Vault could use up to 128, which caused problems. If you want to use Vault with Consul 1.6.3 through 1.7.0, you should change the value to 200.
|
||||
Starting with Consul 1.7.1 this is the new default.
|
||||
|
||||
|
@ -361,7 +361,7 @@ datacenter". All configuration is backwards compatible and shouldn't need to
|
|||
change prior to upgrade although it's strongly recommended to migrate ACL
|
||||
configuration to the new syntax soon after upgrade. This includes moving to
|
||||
`primary_datacenter` rather than `acl_datacenter` and `acl_*` to the new [ACL
|
||||
block](/docs/agent/config/agent-config-files#acl).
|
||||
block](/docs/agent/config/config-files#acl).
|
||||
|
||||
Datacenters can be upgraded in any order although secondaries will remain in
|
||||
[Legacy ACL mode](#legacy-acl-mode) until the primary datacenter is fully
|
||||
|
@ -488,11 +488,11 @@ The following previously deprecated fields and config options have been removed:
|
|||
Consul 1.0.1 (and earlier versions of Consul) checked for raft snapshots every
|
||||
5 seconds, and created new snapshots for every 8192 writes. These defaults cause
|
||||
constant disk IO in large busy clusters. Consul 1.1.0 increases these to larger values,
|
||||
and makes them tunable via the [raft_snapshot_interval](/docs/agent/config/agent-config-files#_raft_snapshot_interval) and
|
||||
[raft_snapshot_threshold](/docs/agent/config/agent-config-files#_raft_snapshot_threshold) parameters. We recommend
|
||||
and makes them tunable via the [raft_snapshot_interval](/docs/agent/config/config-files#_raft_snapshot_interval) and
|
||||
[raft_snapshot_threshold](/docs/agent/config/config-files#_raft_snapshot_threshold) parameters. We recommend
|
||||
keeping the new defaults. However, operators can go back to the old defaults by changing their
|
||||
config if they prefer more frequent snapshots. See the documentation for [raft_snapshot_interval](/docs/agent/config/agent-config-files#_raft_snapshot_interval)
|
||||
and [raft_snapshot_threshold](/docs/agent/config/agent-config-files#_raft_snapshot_threshold) to understand the trade-offs
|
||||
config if they prefer more frequent snapshots. See the documentation for [raft_snapshot_interval](/docs/agent/config/config-files#_raft_snapshot_interval)
|
||||
and [raft_snapshot_threshold](/docs/agent/config/config-files#_raft_snapshot_threshold) to understand the trade-offs
|
||||
when tuning these.
|
||||
|
||||
## Consul 1.0.7
|
||||
|
@ -520,7 +520,7 @@ before proceeding.
|
|||
#### Carefully Check and Remove Stale Servers During Rolling Upgrades
|
||||
|
||||
Consul 1.0 (and earlier versions of Consul when running with [Raft protocol
|
||||
3](/docs/agent/config/agent-config-files#_raft_protocol) had an issue where performing
|
||||
3](/docs/agent/config/config-files#_raft_protocol) had an issue where performing
|
||||
rolling updates of Consul servers could result in an outage from old servers
|
||||
remaining in the cluster.
|
||||
[Autopilot](https://learn.hashicorp.com/tutorials/consul/autopilot-datacenter-operations)
|
||||
|
@ -541,7 +541,7 @@ Please be sure to read over all the details here before upgrading.
|
|||
|
||||
#### Raft Protocol Now Defaults to 3
|
||||
|
||||
The [`-raft-protocol`](/docs/agent/config/agent-config-cli#_raft_protocol) default has
|
||||
The [`-raft-protocol`](/docs/agent/config/cli-flags#_raft_protocol) default has
|
||||
been changed from 2 to 3, enabling all
|
||||
[Autopilot](https://learn.hashicorp.com/tutorials/consul/autopilot-datacenter-operations)
|
||||
features by default.
|
||||
|
@ -570,7 +570,7 @@ servers, and then slowly stand down each of the older servers in a similar
|
|||
fashion.
|
||||
|
||||
When using Raft protocol version 3, servers are identified by their
|
||||
[`-node-id`](/docs/agent/config/agent-config-cli#_node_id) instead of their IP address
|
||||
[`-node-id`](/docs/agent/config/cli-flags#_node_id) instead of their IP address
|
||||
when Consul makes changes to its internal Raft quorum configuration. This means
|
||||
that once a cluster has been upgraded with servers all running Raft protocol
|
||||
version 3, it will no longer allow servers running any older Raft protocol
|
||||
|
@ -585,7 +585,7 @@ to map the server to its node ID in the Raft quorum configuration.
|
|||
As part of supporting the [HCL](https://github.com/hashicorp/hcl#syntax) format
|
||||
for Consul's config files, an `.hcl` or `.json` extension is required for all
|
||||
config files loaded by Consul, even when using the
|
||||
[`-config-file`](/docs/agent/config/agent-config-cli#_config_file) argument to specify a
|
||||
[`-config-file`](/docs/agent/config/cli-flags#_config_file) argument to specify a
|
||||
file directly.
|
||||
|
||||
#### Service Definition Parameter Case changed
|
||||
|
@ -602,30 +602,30 @@ upgrading. Here's the complete list of removed options and their equivalents:
|
|||
|
||||
| Removed Option | Equivalent |
|
||||
| ------------------------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `-dc` | [`-datacenter`](/docs/agent/config/agent-config-cli#_datacenter) |
|
||||
| `-retry-join-azure-tag-name` | [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) |
|
||||
| `-retry-join-azure-tag-value` | [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) |
|
||||
| `-retry-join-ec2-region` | [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) |
|
||||
| `-retry-join-ec2-tag-key` | [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) |
|
||||
| `-retry-join-ec2-tag-value` | [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) |
|
||||
| `-retry-join-gce-credentials-file` | [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) |
|
||||
| `-retry-join-gce-project-name` | [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) |
|
||||
| `-retry-join-gce-tag-name` | [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) |
|
||||
| `-retry-join-gce-zone-pattern` | [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) |
|
||||
| `-dc` | [`-datacenter`](/docs/agent/config/cli-flags#_datacenter) |
|
||||
| `-retry-join-azure-tag-name` | [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) |
|
||||
| `-retry-join-azure-tag-value` | [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) |
|
||||
| `-retry-join-ec2-region` | [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) |
|
||||
| `-retry-join-ec2-tag-key` | [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) |
|
||||
| `-retry-join-ec2-tag-value` | [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) |
|
||||
| `-retry-join-gce-credentials-file` | [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) |
|
||||
| `-retry-join-gce-project-name` | [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) |
|
||||
| `-retry-join-gce-tag-name` | [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) |
|
||||
| `-retry-join-gce-zone-pattern` | [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) |
|
||||
| `addresses.rpc` | None, the RPC server for CLI commands is no longer supported. |
|
||||
| `advertise_addrs` | [`ports`](/docs/agent/config/agent-config-files#ports) with [`advertise_addr`](/docs/agent/config/agent-config-files#advertise_addr) and/or [`advertise_addr_wan`](/docs/agent/config/agent-config-files#advertise_addr_wan) |
|
||||
| `dogstatsd_addr` | [`telemetry.dogstatsd_addr`](/docs/agent/config/agent-config-files#telemetry-dogstatsd_addr) |
|
||||
| `dogstatsd_tags` | [`telemetry.dogstatsd_tags`](/docs/agent/config/agent-config-files#telemetry-dogstatsd_tags) |
|
||||
| `http_api_response_headers` | [`http_config.response_headers`](/docs/agent/config/agent-config-files#response_headers) |
|
||||
| `advertise_addrs` | [`ports`](/docs/agent/config/config-files#ports) with [`advertise_addr`](/docs/agent/config/config-files#advertise_addr) and/or [`advertise_addr_wan`](/docs/agent/config/config-files#advertise_addr_wan) |
|
||||
| `dogstatsd_addr` | [`telemetry.dogstatsd_addr`](/docs/agent/config/config-files#telemetry-dogstatsd_addr) |
|
||||
| `dogstatsd_tags` | [`telemetry.dogstatsd_tags`](/docs/agent/config/config-files#telemetry-dogstatsd_tags) |
|
||||
| `http_api_response_headers` | [`http_config.response_headers`](/docs/agent/config/config-files#response_headers) |
|
||||
| `ports.rpc` | None, the RPC server for CLI commands is no longer supported. |
|
||||
| `recursor` | [`recursors`](https://github.com/hashicorp/consul/blob/main/website/pages/docs/agent/config/agent-config-files.mdx#recursors) |
|
||||
| `retry_join_azure` | [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) |
|
||||
| `retry_join_ec2` | [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) |
|
||||
| `retry_join_gce` | [`-retry-join`](/docs/agent/config/agent-config-cli#_retry_join) |
|
||||
| `statsd_addr` | [`telemetry.statsd_address`](https://github.com/hashicorp/consul/blob/main/website/pages/docs/agent/config/agent-config-files.mdx#telemetry-statsd_address) |
|
||||
| `statsite_addr` | [`telemetry.statsite_address`](https://github.com/hashicorp/consul/blob/main/website/pages/docs/agent/config/agent-config-files.mdx#telemetry-statsite_address) |
|
||||
| `statsite_prefix` | [`telemetry.metrics_prefix`](/docs/agent/config/agent-config-files#telemetry-metrics_prefix) |
|
||||
| `telemetry.statsite_prefix` | [`telemetry.metrics_prefix`](/docs/agent/config/agent-config-files#telemetry-metrics_prefix) |
|
||||
| `recursor` | [`recursors`](https://github.com/hashicorp/consul/blob/main/website/pages/docs/agent/config/config-files.mdx#recursors) |
|
||||
| `retry_join_azure` | [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) |
|
||||
| `retry_join_ec2` | [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) |
|
||||
| `retry_join_gce` | [`-retry-join`](/docs/agent/config/cli-flags#_retry_join) |
|
||||
| `statsd_addr` | [`telemetry.statsd_address`](https://github.com/hashicorp/consul/blob/main/website/pages/docs/agent/config/config-files.mdx#telemetry-statsd_address) |
|
||||
| `statsite_addr` | [`telemetry.statsite_address`](https://github.com/hashicorp/consul/blob/main/website/pages/docs/agent/config/config-files.mdx#telemetry-statsite_address) |
|
||||
| `statsite_prefix` | [`telemetry.metrics_prefix`](/docs/agent/config/config-files#telemetry-metrics_prefix) |
|
||||
| `telemetry.statsite_prefix` | [`telemetry.metrics_prefix`](/docs/agent/config/config-files#telemetry-metrics_prefix) |
|
||||
| (service definitions) `serviceid` | [`service_id`](/docs/agent/services) |
|
||||
| (service definitions) `dockercontainerid` | [`docker_container_id`](/docs/agent/services) |
|
||||
| (service definitions) `tlsskipverify` | [`tls_skip_verify`](/docs/agent/services) |
|
||||
|
@ -635,7 +635,7 @@ upgrading. Here's the complete list of removed options and their equivalents:
|
|||
|
||||
Since the `statsite_prefix` configuration option applied to all telemetry
|
||||
providers, `statsite_prefix` was renamed to
|
||||
[`metrics_prefix`](/docs/agent/config/agent-config-files#telemetry-metrics_prefix).
|
||||
[`metrics_prefix`](/docs/agent/config/config-files#telemetry-metrics_prefix).
|
||||
Configuration files will need to be updated when upgrading to this version of
|
||||
Consul.
|
||||
|
||||
|
@ -647,8 +647,8 @@ wrongly stated that you could configure both host and port.
|
|||
|
||||
#### Escaping Behavior Changed for go-discover Configs
|
||||
|
||||
The format for [`-retry-join`](/docs/agent/config/agent-config-cli#retry-join) and
|
||||
[`-retry-join-wan`](/docs/agent/config/agent-config-cli#retry-join-wan) values that use
|
||||
The format for [`-retry-join`](/docs/agent/config/cli-flags#retry-join) and
|
||||
[`-retry-join-wan`](/docs/agent/config/cli-flags#retry-join-wan) values that use
|
||||
[go-discover](https://github.com/hashicorp/go-discover) cloud auto joining has
|
||||
changed. Values in `key=val` sequences must no longer be URL encoded and can be
|
||||
provided as literals as long as they do not contain spaces, backslashes `\` or
|
||||
|
@ -766,7 +766,7 @@ invalid health checks would get skipped.
|
|||
|
||||
#### Script Checks Are Now Opt-In
|
||||
|
||||
A new [`enable_script_checks`](/docs/agent/config/agent-config-cli#_enable_script_checks)
|
||||
A new [`enable_script_checks`](/docs/agent/config/cli-flags#_enable_script_checks)
|
||||
configuration option was added, and defaults to `false`, meaning that in order
|
||||
to allow an agent to run health checks that execute scripts, this will need to
|
||||
be configured and set to `true`. This provides a safer out-of-the-box
|
||||
|
@ -788,10 +788,10 @@ for more information.
|
|||
|
||||
Consul releases will no longer include a `web_ui.zip` file with the compiled
|
||||
web assets. These have been built in to the Consul binary since the 0.7.x
|
||||
series and can be enabled with the [`-ui`](/docs/agent/config/agent-config-cli#_ui)
|
||||
series and can be enabled with the [`-ui`](/docs/agent/config/cli-flags#_ui)
|
||||
configuration option. These built-in web assets have always been identical to
|
||||
the contents of the `web_ui.zip` file for each release. The
|
||||
[`-ui-dir`](/docs/agent/config/agent-config-cli#_ui_dir) option is still available for
|
||||
[`-ui-dir`](/docs/agent/config/cli-flags#_ui_dir) option is still available for
|
||||
hosting customized versions of the web assets, but the vast majority of Consul
|
||||
users can just use the built in web assets.
|
||||
|
||||
|
@ -823,12 +823,12 @@ to the following commands:
|
|||
|
||||
#### Version 8 ACLs Are Now Opt-Out
|
||||
|
||||
The [`acl_enforce_version_8`](/docs/agent/config/agent-config-files#acl_enforce_version_8)
|
||||
The [`acl_enforce_version_8`](/docs/agent/config/config-files#acl_enforce_version_8)
|
||||
configuration now defaults to `true` to enable full version 8 ACL support by
|
||||
default. If you are upgrading an existing cluster with ACLs enabled, you will
|
||||
need to set this to `false` during the upgrade on **both Consul agents and
|
||||
Consul servers**. Version 8 ACLs were also changed so that
|
||||
[`acl_datacenter`](/docs/agent/config/agent-config-files#acl_datacenter) must be set on
|
||||
[`acl_datacenter`](/docs/agent/config/config-files#acl_datacenter) must be set on
|
||||
agents in order to enable the agent-side enforcement of ACLs. This makes for a
|
||||
smoother experience in clusters where ACLs aren't enabled at all, but where the
|
||||
agents would have to wait to contact a Consul server before learning that.
|
||||
|
@ -836,14 +836,14 @@ agents would have to wait to contact a Consul server before learning that.
|
|||
#### Remote Exec Is Now Opt-In
|
||||
|
||||
The default for
|
||||
[`disable_remote_exec`](/docs/agent/config/agent-config-files#disable_remote_exec) was
|
||||
[`disable_remote_exec`](/docs/agent/config/config-files#disable_remote_exec) was
|
||||
changed to "true", so now operators need to opt-in to having agents support
|
||||
running commands remotely via [`consul exec`](/commands/exec).
|
||||
|
||||
#### Raft Protocol Version Compatibility
|
||||
|
||||
When upgrading to Consul 0.8.0 from a version lower than 0.7.0, users will need
|
||||
to set the [`-raft-protocol`](/docs/agent/config/agent-config-cli#_raft_protocol) option
|
||||
to set the [`-raft-protocol`](/docs/agent/config/cli-flags#_raft_protocol) option
|
||||
to 1 in order to maintain backwards compatibility with the old servers during
|
||||
the upgrade. After the servers have been migrated to version 0.8.0,
|
||||
`-raft-protocol` can be moved up to 2 and the servers restarted to match the
|
||||
|
@ -878,7 +878,7 @@ process to reap child processes.
|
|||
|
||||
#### DNS Resiliency Defaults
|
||||
|
||||
The default for [`max_stale`](/docs/agent/config/agent-config-files#max_stale) has been
|
||||
The default for [`max_stale`](/docs/agent/config/config-files#max_stale) has been
|
||||
increased from 5 seconds to a near-indefinite threshold (10 years) to allow DNS
|
||||
queries to continue to be served in the event of a long outage with no leader.
|
||||
A new telemetry counter was added at `consul.dns.stale_queries` to track when
|
||||
|
@ -892,7 +892,7 @@ to be aware of during an upgrade are categorized below.
|
|||
#### Performance Timing Defaults and Tuning
|
||||
|
||||
Consul 0.7 now defaults the DNS configuration to allow for stale queries by
|
||||
defaulting [`allow_stale`](/docs/agent/config/agent-config-files#allow_stale) to true for
|
||||
defaulting [`allow_stale`](/docs/agent/config/config-files#allow_stale) to true for
|
||||
better utilization of available servers. If you want to retain the previous
|
||||
behavior, set the following configuration:
|
||||
|
||||
|
@ -905,7 +905,7 @@ behavior, set the following configuration:
|
|||
```
|
||||
|
||||
Consul also 0.7 introduced support for tuning Raft performance using a new
|
||||
[performance configuration block](/docs/agent/config/agent-config-files#performance). Also,
|
||||
[performance configuration block](/docs/agent/config/config-files#performance). Also,
|
||||
the default Raft timing is set to a lower-performance mode suitable for
|
||||
[minimal Consul servers](/docs/install/performance#minimum).
|
||||
|
||||
|
@ -925,8 +925,8 @@ See the [Server Performance](/docs/install/performance) guide for more details.
|
|||
|
||||
#### Leave-Related Configuration Defaults
|
||||
|
||||
The default behavior of [`leave_on_terminate`](/docs/agent/config/agent-config-files#leave_on_terminate)
|
||||
and [`skip_leave_on_interrupt`](/docs/agent/config/agent-config-files#skip_leave_on_interrupt)
|
||||
The default behavior of [`leave_on_terminate`](/docs/agent/config/config-files#leave_on_terminate)
|
||||
and [`skip_leave_on_interrupt`](/docs/agent/config/config-files#skip_leave_on_interrupt)
|
||||
are now dependent on whether or not the agent is acting as a server or client:
|
||||
|
||||
- For servers, `leave_on_terminate` defaults to "false" and `skip_leave_on_interrupt`
|
||||
|
@ -965,7 +965,7 @@ using this feature.
|
|||
#### WAN Address Translation in HTTP Endpoints
|
||||
|
||||
Consul version 0.7 added support for translating WAN addresses in certain
|
||||
[HTTP endpoints](/docs/agent/config/agent-config-files#translate_wan_addrs). The servers
|
||||
[HTTP endpoints](/docs/agent/config/config-files#translate_wan_addrs). The servers
|
||||
and the agents need to be running version 0.7 or later in order to use this
|
||||
feature.
|
||||
|
||||
|
@ -1047,7 +1047,7 @@ which require it:
|
|||
}
|
||||
|
||||
When the DNS interface is queried, the agent's
|
||||
[`acl_token`](/docs/agent/config/agent-config-files#acl_token) is used, so be sure
|
||||
[`acl_token`](/docs/agent/config/config-files#acl_token) is used, so be sure
|
||||
that token has sufficient privileges to return the DNS records you
|
||||
expect to retrieve from it.
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
used instead. The scheme can also be set to HTTPS by setting the environment
|
||||
variable `CONSUL_HTTP_SSL=true`. This may be a unix domain socket using
|
||||
`unix:///path/to/socket` if the [agent is configured to
|
||||
listen](/docs/agent/config/agent-config-files#addresses) that way.
|
||||
listen](/docs/agent/config/config-files#addresses) that way.
|
||||
|
||||
- `-tls-server-name=<value>` - The server name to use as the SNI host when
|
||||
connecting via TLS. This can also be specified via the `CONSUL_TLS_SERVER_NAME`
|
||||
|
|
|
@ -778,11 +778,11 @@
|
|||
},
|
||||
{
|
||||
"title": "CLI Reference",
|
||||
"path": "agent/config/agent-config-cli"
|
||||
"path": "agent/config/cli-flags"
|
||||
},
|
||||
{
|
||||
"title": "Configuration Reference",
|
||||
"path": "agent/config/agent-config-files"
|
||||
"path": "agent/config/config-files"
|
||||
}
|
||||
]
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue