From 4bd782ce3430e632172402eab6ed9c16e8e24eb9 Mon Sep 17 00:00:00 2001 From: Cynthia Coan Date: Sat, 3 Aug 2019 17:12:21 -0600 Subject: [PATCH 1/2] utilize new address type in pgv for better errors this utilizes the new "address" validation type for better error messages when validating configuration of the "address" type. Signed-off-by: Cynthia Coan --- api/envoy/api/v2/core/address.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/envoy/api/v2/core/address.proto b/api/envoy/api/v2/core/address.proto index 88689e2648ce6..76b473e12b6b9 100644 --- a/api/envoy/api/v2/core/address.proto +++ b/api/envoy/api/v2/core/address.proto @@ -44,7 +44,7 @@ message SocketAddress { // address must be an IP (*STATIC* or *EDS* clusters) or a hostname resolved by DNS // (*STRICT_DNS* or *LOGICAL_DNS* clusters). Address resolution can be customized // via :ref:`resolver_name `. - string address = 2 [(validate.rules).string.min_bytes = 1]; + string address = 2 [(validate.rules).string.address = true]; oneof port_specifier { option (validate.required) = true; uint32 port_value = 3 [(validate.rules).uint32.lte = 65535]; From a524ab96f2c16e32745162e6dd4bbc077d76f59f Mon Sep 17 00:00:00 2001 From: Cynthia Coan Date: Sat, 3 Aug 2019 18:31:55 -0600 Subject: [PATCH 2/2] update dns addresses to be valid Signed-off-by: Cynthia Coan --- configs/envoy_service_to_service_v2.template.yaml | 4 ++-- examples/lua/envoy.yaml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/configs/envoy_service_to_service_v2.template.yaml b/configs/envoy_service_to_service_v2.template.yaml index 531322b3a14ba..fd83a40f609ac 100644 --- a/configs/envoy_service_to_service_v2.template.yaml +++ b/configs/envoy_service_to_service_v2.template.yaml @@ -398,11 +398,11 @@ static_resources: - endpoint: address: socket_address: - address: main_website.com + address: main.website.com port_value: 443 protocol: TCP tls_context: - sni: www.main_website.com + sni: www.main.website.com - name: local_service connect_timeout: 0.25s type: STATIC diff --git a/examples/lua/envoy.yaml b/examples/lua/envoy.yaml index 4f98481091fb7..b4a00ffcf6800 100644 --- a/examples/lua/envoy.yaml +++ b/examples/lua/envoy.yaml @@ -52,7 +52,7 @@ static_resources: - endpoint: address: socket_address: - address: web_service + address: web.service.com port_value: 80 admin: access_log_path: "/dev/null"