How the proxy runs Envoy
A proxy runs Envoy with the configuration that you provide. You supply an Envoy bootstrap configuration file and an optional archive of supporting files. ELB for Envoy runs the Envoy processes, keeps them patched, and scales them with traffic. This section describes which Envoy functionality is available in the bootstrap configuration and over xDS, and what ELB for Envoy adds to your configuration.
Topics
Envoy versions
You choose the Envoy version when you create a proxy, through the proxyVersion
field. The value is a major and minor version. At launch, ELB for Envoy supports Envoy
1.40 only, and the CreateProxy operation rejects any other version.
Within a version, ELB for Envoy applies patch releases and operating system updates for you.
Bootstrap configuration
The configuration file that you pass as configurationFile is an Envoy
bootstrap YAML document. ELB for Envoy accepts only the following bootstrap fields and rejects a
configuration file that sets any other field. For how ELB for Envoy validates your configuration,
see Configuration validation. To
understand how Envoy structures configuration, including bootstrap and dynamic (xDS)
resources, see Envoy configuration for ELB for Envoy.
| Field | Purpose |
|---|---|
|
Statically defined listeners, clusters, and secrets. |
|
LDS, CDS, and ADS configuration for xDS control planes. For details, see Dynamic configuration (xDS). |
|
Health discovery service configuration for cluster endpoint health. |
|
Push Envoy statistics to your own collectors, for example the OpenTelemetry stats sink. |
|
Control how Envoy statistics are tagged and processed. |
|
Envoy's admin interface. For details, see Use the Envoy admin interface securely. |
|
The format of Envoy's application logs, for example structured JSON logging. |
|
Settings that apply to all upstream clusters, such as
|
|
The cluster name in the node identity presented to your xDS control plane.
When you omit it, ELB for Envoy uses your proxy name. The other |
ELB for Envoy delivers Envoy application logs to Amazon CloudWatch Logs (CloudWatch Logs), and you can push Envoy
statistics with stats_sinks. For details, see Monitor a proxy.
Configuration validation
The CreateProxy and UpdateProxyConfiguration operations validate
your configuration file synchronously against the Envoy bootstrap schema of your chosen
proxyVersion. Validation checks the following:
-
The document is well-formed YAML.
-
Unknown fields are rejected, and every
typed_configextension type resolves against that Envoy version's API. -
Field-level constraints declared by Envoy's protos are met.
A schema violation fails the call with a ValidationException that names the
offending field.
Passing validation does not guarantee that the process starts. Envoy performs further
checks at startup, for example that referenced files exist. Before ELB for Envoy starts or
restarts Envoy, it runs envoy --mode validate against your full configuration. A
configuration that fails this second stage is not applied. On an update, the previously
running configuration keeps serving traffic.
How ELB for Envoy runs your Envoy process
Envoy runs as an unprivileged, sandboxed process:
-
The process sees a private filesystem root that contains your configuration file and extracted archive.
-
It can bind privileged ports (below 1024) directly.
-
It binds listeners on the network interface in your VPC. Your security groups control reachability.
ELB for Envoy owns the Envoy command line. It sets the node identity flags
(--service-node to the instance ID, --service-cluster to your proxy
name unless your bootstrap sets node.cluster, and --service-zone to
the Availability Zone), the drain timers, and the log level derived from your proxy
attributes. You cannot set Envoy CLI flags yourself.
Configuration archive
If your bootstrap configuration references files on disk, such as certificates, response
bodies, or xDS seed files, package them in a ZIP file and pass it as
configurationArchive:
-
ELB for Envoy extracts the archive into the directory that Envoy sees as its filesystem root. An entry
etc/envoy/response.htmlis readable at/etc/envoy/response.html. -
A file named
envoy.yamlat the archive root is ignored. The authoritative bootstrap is always theconfigurationFilethat you supply. -
When you update only the archive, ELB for Envoy moves the new files into place without restarting Envoy. Filters that read local files through a data source with a
watched_directorypick up the new contents at runtime. This is how you rotate certificates or update file-based xDS resources without a restart.
Configuration updates and connection draining
Updating the configuration file through the UpdateProxyConfiguration operation
restarts Envoy using its hot restartConnection: close header and HTTP/2 connections receive GOAWAY
frames. The drain period is fixed at 60 seconds.
ELB for Envoy does not actively close TCP and WebSocket connections during a drain. Draining relies on your clients periodically recycling connections.
Updating only the archive does not restart Envoy. You can retrieve the currently stored
configuration with the GetProxyConfigurationContents operation. For the update
procedure, see Update a proxy configuration.
Dynamic configuration (xDS)
ELB for Envoy supports Envoy's dynamic configuration model. Define your xDS control plane
clusters in static_resources and point dynamic_resources (LDS, CDS,
or ADS) at them, as you would when running Envoy yourself. ELB for Envoy does not restrict the
types of dynamic updates that Envoy receives. Envoy's own semantics apply, including that
statically defined resources cannot be overwritten dynamically.
To update your control plane endpoints or rotate its TLS certificates without a restart,
load them from files in your configuration archive using watched_directory data
sources, or serve them from your control plane itself.
What ELB for Envoy adds to your configuration
ELB for Envoy injects a small set of managed elements into the configuration that Envoy loads. They apply to both statically defined resources and resources delivered over xDS. You do not need to, and cannot, configure them yourself.
- Health and management extensions
-
ELB for Envoy adds bootstrap extensions that serve internal health and management endpoints. They run in a separate network namespace, so they do not conflict with your listeners or loopback ports.
- TLS Inspector with JA3 and JA4 fingerprinting
-
ELB for Envoy places a TLS Inspector
listener filter, with JA3 and JA4 fingerprinting enabled, at the front of every listener's filter chain. If your configuration already declares a TLS Inspector, ELB for Envoy replaces it with the fingerprinting-enabled one. The fingerprints are used for AWS WAF inspection. For details, see Protect a proxy with AWS WAF. - AWS WAF filter and cluster
-
When a web ACL is associated with your proxy, ELB for Envoy inserts an AWS WAF filter into the HTTP filter chain of every
HttpConnectionManagerand adds a managed cluster for the AWS WAF data plane. For details, see Protect a proxy with AWS WAF.