From 57e5b06c1790ce83b799f0d9c1fceafee34476cf Mon Sep 17 00:00:00 2001 From: Blake Covarrubias Date: Mon, 2 Aug 2021 12:50:51 -0700 Subject: [PATCH] docs: Document supported `consul connect` env vars (#10667) Document the ability to specify `-sidecar-for` and `-proxy-id` flags via environment variables. --- website/content/commands/connect/envoy.mdx | 5 ++++- website/content/commands/connect/proxy.mdx | 4 +++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/website/content/commands/connect/envoy.mdx b/website/content/commands/connect/envoy.mdx index c23df6833..92be07970 100644 --- a/website/content/commands/connect/envoy.mdx +++ b/website/content/commands/connect/envoy.mdx @@ -54,7 +54,8 @@ proxy configuration needed. - `-proxy-id` - The [proxy service](/docs/connect/registration/service-registration) ID. This service ID must already be registered with the local agent unless a gateway is being - registered with the `-register` flag. + registered with the `-register` flag. As of Consul 1.8.0, this can also be + specified via the `CONNECT_PROXY_ID` environment variable. - `-envoy-binary` - The full path to a specific Envoy binary to exec. By default the current `$PATH` is searched for `envoy`. @@ -110,6 +111,8 @@ proxy configuration needed. `proxy.destination_service_id` equal to the passed value must be present. If multiple proxy registrations targeting the same local service instance are present the command will error and `-proxy-id` should be used instead. + As of Consul 1.8.0, this can also be specified via the `CONNECT_SIDECAR_FOR` + environment variable. -> **Note:** If ACLs are enabled, a token granting `service:write` for the _target_ service (configured in `proxy.destination_service_name`) must be diff --git a/website/content/commands/connect/proxy.mdx b/website/content/commands/connect/proxy.mdx index 036e8a588..0b7d19aec 100644 --- a/website/content/commands/connect/proxy.mdx +++ b/website/content/commands/connect/proxy.mdx @@ -34,10 +34,12 @@ Usage: `consul connect proxy [options]` `proxy.destination_service_id` equal to the passed value must be present. If multiple proxy registrations targeting the same local service instance are present the command will error and `-proxy-id` should be used instead. + This can also be specified via the `CONNECT_SIDECAR_FOR` environment variable. - `-proxy-id` - The [proxy service](/docs/connect/registration/service-registration) ID on the - local agent. This must already be present on the local agent. + local agent. This must already be present on the local agent. This option + can also be specified via the `CONNECT_PROXY_ID` environment variable. - `-log-level` - Specifies the log level.