From 9b8edddff453665f84eafef57fdfc0793c9fe0b6 Mon Sep 17 00:00:00 2001 From: Marcin Skalski Date: Thu, 30 Jan 2025 15:08:10 +0100 Subject: [PATCH] fix(e2e): properly cleanup policies after envoyconfig test (#12711) --------- Signed-off-by: Marcin Skalski --- .../universal/envoyconfig/envoyconfig.go | 20 +- .../inbound.demo-client.golden.json | 854 +++++++-------- .../inbound.test-server.golden.json | 952 ++++++++--------- .../outbound.demo-client.golden.json | 874 ++++++++-------- .../outbound.test-server.golden.json | 972 +++++++++--------- 5 files changed, 1834 insertions(+), 1838 deletions(-) diff --git a/test/e2e_env/universal/envoyconfig/envoyconfig.go b/test/e2e_env/universal/envoyconfig/envoyconfig.go index c76238eeaca9..cd4c130a6a0c 100644 --- a/test/e2e_env/universal/envoyconfig/envoyconfig.go +++ b/test/e2e_env/universal/envoyconfig/envoyconfig.go @@ -13,6 +13,8 @@ import ( mesh_proto "github.com/kumahq/kuma/api/mesh/v1alpha1" "github.com/kumahq/kuma/api/openapi/types" api_common "github.com/kumahq/kuma/api/openapi/types/common" + meshaccesslog "github.com/kumahq/kuma/pkg/plugins/policies/meshaccesslog/api/v1alpha1" + meshtimeout "github.com/kumahq/kuma/pkg/plugins/policies/meshtimeout/api/v1alpha1" "github.com/kumahq/kuma/pkg/test" "github.com/kumahq/kuma/pkg/test/matchers" "github.com/kumahq/kuma/pkg/test/resources/builders" @@ -60,18 +62,12 @@ func EnvoyConfigTest() { }) E2EAfterEach(func() { - // delete all meshtimeout policies - out, err := universal.Cluster.GetKumactlOptions().RunKumactlAndGetOutput("get", "meshtimeouts", "--mesh", meshName, "-o", "json") - Expect(err).ToNot(HaveOccurred()) - var output struct { - Items []struct { - Name string `json:"name"` - } `json:"items"` - } - Expect(json.Unmarshal([]byte(out), &output)).To(Succeed()) - for _, item := range output.Items { - Expect(universal.Cluster.GetKumactlOptions().RunKumactl("delete", "meshtimeout", item.Name, "--mesh", meshName)).To(Succeed()) - } + Expect(DeleteMeshResources( + universal.Cluster, + meshName, + meshtimeout.MeshTimeoutResourceTypeDescriptor, + meshaccesslog.MeshAccessLogResourceTypeDescriptor, + )).To(Succeed()) }) getConfig := func(dpp string) string { diff --git a/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/inbound.demo-client.golden.json b/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/inbound.demo-client.golden.json index 65e235c44867..b7bc283b83ee 100644 --- a/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/inbound.demo-client.golden.json +++ b/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/inbound.demo-client.golden.json @@ -1,457 +1,457 @@ { - "diff": [ - { - "op": "add", - "path": "/type.googleapis.com~1envoy.config.listener.v3.Listener/inbound:IP_REDACTED:3000/filterChains/0/filters/0/typedConfig/accessLog", - "value": [ + "diff": [ { - "name": "envoy.access_loggers.file", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", - "logFormat": { - "textFormatSource": { - "inlineString": "[%START_TIME%]\n" - } - }, - "path": "/dev/stdout" - } - } - ] - } - ], - "xds": { - "type.googleapis.com/envoy.config.cluster.v3.Cluster": { - "envoyconfig_demo-client__kuma-3_msvc_3000": { - "name": "envoyconfig_demo-client__kuma-3_msvc_3000", - "type": "EDS", - "edsClusterConfig": { - "edsConfig": { - "ads": {}, - "resourceApiVersion": "V3" - } - }, - "typedExtensionProtocolOptions": { - "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { - "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", - "explicitHttpConfig": { - "http2ProtocolOptions": {} - } - } - } - }, - "envoyconfig_test-server__kuma-3_msvc_80": { - "name": "envoyconfig_test-server__kuma-3_msvc_80", - "type": "EDS", - "edsClusterConfig": { - "edsConfig": { - "ads": {}, - "resourceApiVersion": "V3" - } - }, - "typedExtensionProtocolOptions": { - "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { - "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", - "explicitHttpConfig": { - "http2ProtocolOptions": {} - } - } - } - }, - "inbound:passthrough:ipv4": { - "name": "inbound:passthrough:ipv4", - "altStatName": "inbound_passthrough_ipv4", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED", - "upstreamBindConfig": { - "sourceAddress": { - "address": "IP_REDACTED", - "portValue": 0 - } - } - }, - "inbound:passthrough:ipv6": { - "name": "inbound:passthrough:ipv6", - "altStatName": "inbound_passthrough_ipv6", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED", - "upstreamBindConfig": { - "sourceAddress": { - "address": "IP_REDACTED", - "portValue": 0 - } - } - }, - "localhost:3000": { - "name": "localhost:3000", - "altStatName": "localhost_3000", - "type": "STATIC", - "connectTimeout": "10s", - "loadAssignment": { - "clusterName": "localhost:3000", - "endpoints": [ - { - "lbEndpoints": [ + "op": "add", + "path": "/type.googleapis.com~1envoy.config.listener.v3.Listener/inbound:IP_REDACTED:3000/filterChains/0/filters/0/typedConfig/accessLog", + "value": [ { - "endpoint": { - "address": { - "socketAddress": { + "name": "envoy.access_loggers.file", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", + "logFormat": { + "textFormatSource": { + "inlineString": "[%START_TIME%]\n" + } + }, + "path": "/dev/stdout" + } + } + ] + } + ], + "xds": { + "type.googleapis.com/envoy.config.cluster.v3.Cluster": { + "envoyconfig_demo-client__kuma-3_msvc_3000": { + "edsClusterConfig": { + "edsConfig": { + "ads": {}, + "resourceApiVersion": "V3" + } + }, + "name": "envoyconfig_demo-client__kuma-3_msvc_3000", + "type": "EDS", + "typedExtensionProtocolOptions": { + "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { + "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", + "explicitHttpConfig": { + "http2ProtocolOptions": {} + } + } + } + }, + "envoyconfig_test-server__kuma-3_msvc_80": { + "edsClusterConfig": { + "edsConfig": { + "ads": {}, + "resourceApiVersion": "V3" + } + }, + "name": "envoyconfig_test-server__kuma-3_msvc_80", + "type": "EDS", + "typedExtensionProtocolOptions": { + "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { + "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", + "explicitHttpConfig": { + "http2ProtocolOptions": {} + } + } + } + }, + "inbound:passthrough:ipv4": { + "altStatName": "inbound_passthrough_ipv4", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "inbound:passthrough:ipv4", + "type": "ORIGINAL_DST", + "upstreamBindConfig": { + "sourceAddress": { "address": "IP_REDACTED", - "portValue": 3000 - } + "portValue": 0 + } + } + }, + "inbound:passthrough:ipv6": { + "altStatName": "inbound_passthrough_ipv6", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "inbound:passthrough:ipv6", + "type": "ORIGINAL_DST", + "upstreamBindConfig": { + "sourceAddress": { + "address": "IP_REDACTED", + "portValue": 0 + } + } + }, + "localhost:3000": { + "altStatName": "localhost_3000", + "connectTimeout": "10s", + "loadAssignment": { + "clusterName": "localhost:3000", + "endpoints": [ + { + "lbEndpoints": [ + { + "endpoint": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 3000 + } + } + } + } + ] + } + ] + }, + "name": "localhost:3000", + "type": "STATIC", + "upstreamBindConfig": { + "sourceAddress": { + "address": "IP_REDACTED", + "portValue": 0 } - } } - ] + }, + "outbound:passthrough:ipv4": { + "altStatName": "outbound_passthrough_ipv4", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "outbound:passthrough:ipv4", + "type": "ORIGINAL_DST" + }, + "outbound:passthrough:ipv6": { + "altStatName": "outbound_passthrough_ipv6", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "outbound:passthrough:ipv6", + "type": "ORIGINAL_DST" } - ] }, - "upstreamBindConfig": { - "sourceAddress": { - "address": "IP_REDACTED", - "portValue": 0 - } - } - }, - "outbound:passthrough:ipv4": { - "name": "outbound:passthrough:ipv4", - "altStatName": "outbound_passthrough_ipv4", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED" - }, - "outbound:passthrough:ipv6": { - "name": "outbound:passthrough:ipv6", - "altStatName": "outbound_passthrough_ipv6", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED" - } - }, - "type.googleapis.com/envoy.config.endpoint.v3.ClusterLoadAssignment": { - "envoyconfig_demo-client__kuma-3_msvc_3000": { - "clusterName": "envoyconfig_demo-client__kuma-3_msvc_3000", - "endpoints": [ - { - "locality": { - "zone": "kuma-3" + "type.googleapis.com/envoy.config.endpoint.v3.ClusterLoadAssignment": { + "envoyconfig_demo-client__kuma-3_msvc_3000": { + "clusterName": "envoyconfig_demo-client__kuma-3_msvc_3000", + "endpoints": [ + { + "lbEndpoints": [ + { + "endpoint": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 3000 + } + } + }, + "loadBalancingWeight": 1, + "metadata": { + "filterMetadata": { + "envoy.lb": { + "kuma.io/zone": "kuma-3", + "team": "client-owners" + }, + "envoy.transport_socket_match": { + "kuma.io/zone": "kuma-3", + "team": "client-owners" + } + } + } + } + ], + "locality": { + "zone": "kuma-3" + } + } + ] }, - "lbEndpoints": [ - { - "endpoint": { - "address": { + "envoyconfig_test-server__kuma-3_msvc_80": { + "clusterName": "envoyconfig_test-server__kuma-3_msvc_80", + "endpoints": [ + { + "lbEndpoints": [ + { + "endpoint": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 80 + } + } + }, + "loadBalancingWeight": 1, + "metadata": { + "filterMetadata": { + "envoy.lb": { + "instance": "1", + "kuma.io/protocol": "http", + "kuma.io/zone": "kuma-3", + "team": "server-owners", + "version": "v1" + }, + "envoy.transport_socket_match": { + "instance": "1", + "kuma.io/protocol": "http", + "kuma.io/zone": "kuma-3", + "team": "server-owners", + "version": "v1" + } + } + } + } + ], + "locality": { + "zone": "kuma-3" + } + } + ] + } + }, + "type.googleapis.com/envoy.config.listener.v3.Listener": { + "inbound:IP_REDACTED:3000": { + "address": { "socketAddress": { - "address": "IP_REDACTED", - "portValue": 3000 + "address": "IP_REDACTED", + "portValue": 3000 } - } }, + "bindToPort": false, + "enableReusePort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "accessLog": [ + { + "name": "envoy.access_loggers.file", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", + "logFormat": { + "textFormatSource": { + "inlineString": "[%START_TIME%]\n" + } + }, + "path": "/dev/stdout" + } + } + ], + "cluster": "localhost:3000", + "idleTimeout": "7200s", + "statPrefix": "localhost_3000" + } + } + ] + } + ], "metadata": { - "filterMetadata": { - "envoy.lb": { - "kuma.io/zone": "kuma-3", - "team": "client-owners" - }, - "envoy.transport_socket_match": { - "kuma.io/zone": "kuma-3", - "team": "client-owners" + "filterMetadata": { + "io.kuma.tags": { + "kuma.io/service": "demo-client", + "kuma.io/zone": "kuma-3", + "team": "client-owners" + } } - } }, - "loadBalancingWeight": 1 - } - ] - } - ] - }, - "envoyconfig_test-server__kuma-3_msvc_80": { - "clusterName": "envoyconfig_test-server__kuma-3_msvc_80", - "endpoints": [ - { - "locality": { - "zone": "kuma-3" + "name": "inbound:IP_REDACTED:3000", + "trafficDirection": "INBOUND" + }, + "inbound:passthrough:ipv4": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15006 + } + }, + "enableReusePort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "inbound:passthrough:ipv4", + "statPrefix": "inbound_passthrough_ipv4" + } + } + ] + } + ], + "name": "inbound:passthrough:ipv4", + "trafficDirection": "INBOUND", + "useOriginalDst": true + }, + "inbound:passthrough:ipv6": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15006 + } + }, + "enableReusePort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "inbound:passthrough:ipv6", + "statPrefix": "inbound_passthrough_ipv6" + } + } + ] + } + ], + "name": "inbound:passthrough:ipv6", + "trafficDirection": "INBOUND", + "useOriginalDst": true }, - "lbEndpoints": [ - { - "endpoint": { - "address": { + "outbound:IP_REDACTED:3000": { + "address": { "socketAddress": { - "address": "IP_REDACTED", - "portValue": 80 + "address": "IP_REDACTED", + "portValue": 3000 } - } }, + "bindToPort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "envoyconfig_demo-client__kuma-3_msvc_3000", + "statPrefix": "envoyconfig_demo-client__kuma-3_msvc_3000" + } + } + ] + } + ], "metadata": { - "filterMetadata": { - "envoy.lb": { - "instance": "1", - "kuma.io/protocol": "http", - "kuma.io/zone": "kuma-3", - "team": "server-owners", - "version": "v1" - }, - "envoy.transport_socket_match": { - "instance": "1", - "kuma.io/protocol": "http", - "kuma.io/zone": "kuma-3", - "team": "server-owners", - "version": "v1" + "filterMetadata": { + "io.kuma.tags": {} } - } }, - "loadBalancingWeight": 1 - } - ] - } - ] - } - }, - "type.googleapis.com/envoy.config.listener.v3.Listener": { - "inbound:IP_REDACTED:3000": { - "name": "inbound:IP_REDACTED:3000", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 3000 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "localhost_3000", - "cluster": "localhost:3000", - "idleTimeout": "7200s", - "accessLog": [ + "name": "outbound:IP_REDACTED:3000", + "trafficDirection": "OUTBOUND" + }, + "outbound:IP_REDACTED:80": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 80 + } + }, + "bindToPort": false, + "filterChains": [ { - "name": "envoy.access_loggers.file", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", - "path": "/dev/stdout", - "logFormat": { - "textFormatSource": { - "inlineString": "[%START_TIME%]\n" - } - } - } + "filters": [ + { + "name": "envoy.filters.network.http_connection_manager", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager", + "httpFilters": [ + { + "name": "envoy.filters.http.router", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.http.router.v3.Router" + } + } + ], + "normalizePath": true, + "routeConfig": { + "name": "outbound:envoyconfig_test-server__kuma-3_msvc_80", + "validateClusters": false, + "virtualHosts": [ + { + "domains": [ + "*" + ], + "name": "envoyconfig_test-server__kuma-3_msvc_80", + "routes": [ + { + "match": { + "prefix": "/" + }, + "name": "9Zuf5Tg79OuZcQITwBbQykxAk2u4fRKrwYn3//AL4Yo=", + "route": { + "cluster": "envoyconfig_test-server__kuma-3_msvc_80", + "timeout": "0s" + } + } + ] + } + ] + }, + "statPrefix": "envoyconfig_test-server__kuma-3_msvc_80" + } + } + ] } - ] - } - } - ] - } - ], - "metadata": { - "filterMetadata": { - "io.kuma.tags": { - "kuma.io/service": "demo-client", - "kuma.io/zone": "kuma-3", - "team": "client-owners" - } - } - }, - "trafficDirection": "INBOUND", - "enableReusePort": false, - "bindToPort": false - }, - "inbound:passthrough:ipv4": { - "name": "inbound:passthrough:ipv4", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15006 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "inbound_passthrough_ipv4", - "cluster": "inbound:passthrough:ipv4" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "INBOUND", - "enableReusePort": false - }, - "inbound:passthrough:ipv6": { - "name": "inbound:passthrough:ipv6", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15006 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "inbound_passthrough_ipv6", - "cluster": "inbound:passthrough:ipv6" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "INBOUND", - "enableReusePort": false - }, - "outbound:IP_REDACTED:3000": { - "name": "outbound:IP_REDACTED:3000", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 3000 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "envoyconfig_demo-client__kuma-3_msvc_3000", - "cluster": "envoyconfig_demo-client__kuma-3_msvc_3000" - } - } - ] - } - ], - "metadata": { - "filterMetadata": { - "io.kuma.tags": {} - } - }, - "trafficDirection": "OUTBOUND", - "bindToPort": false - }, - "outbound:IP_REDACTED:80": { - "name": "outbound:IP_REDACTED:80", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 80 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.http_connection_manager", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager", - "statPrefix": "envoyconfig_test-server__kuma-3_msvc_80", - "routeConfig": { - "name": "outbound:envoyconfig_test-server__kuma-3_msvc_80", - "virtualHosts": [ - { - "name": "envoyconfig_test-server__kuma-3_msvc_80", - "domains": [ - "*" - ], - "routes": [ - { - "name": "9Zuf5Tg79OuZcQITwBbQykxAk2u4fRKrwYn3//AL4Yo=", - "match": { - "prefix": "/" - }, - "route": { - "cluster": "envoyconfig_test-server__kuma-3_msvc_80", - "timeout": "0s" + ], + "metadata": { + "filterMetadata": { + "io.kuma.tags": {} + } + }, + "name": "outbound:IP_REDACTED:80", + "trafficDirection": "OUTBOUND" + }, + "outbound:passthrough:ipv4": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15001 + } + }, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "outbound:passthrough:ipv4", + "statPrefix": "outbound_passthrough_ipv4" + } } - } ] - } - ], - "validateClusters": false - }, - "httpFilters": [ + } + ], + "name": "outbound:passthrough:ipv4", + "trafficDirection": "OUTBOUND", + "useOriginalDst": true + }, + "outbound:passthrough:ipv6": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15001 + } + }, + "filterChains": [ { - "name": "envoy.filters.http.router", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.http.router.v3.Router" - } + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "outbound:passthrough:ipv6", + "statPrefix": "outbound_passthrough_ipv6" + } + } + ] } - ], - "normalizePath": true - } - } - ] - } - ], - "metadata": { - "filterMetadata": { - "io.kuma.tags": {} - } - }, - "trafficDirection": "OUTBOUND", - "bindToPort": false - }, - "outbound:passthrough:ipv4": { - "name": "outbound:passthrough:ipv4", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15001 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "outbound_passthrough_ipv4", - "cluster": "outbound:passthrough:ipv4" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "OUTBOUND" - }, - "outbound:passthrough:ipv6": { - "name": "outbound:passthrough:ipv6", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15001 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "outbound_passthrough_ipv6", - "cluster": "outbound:passthrough:ipv6" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "OUTBOUND" - } + ], + "name": "outbound:passthrough:ipv6", + "trafficDirection": "OUTBOUND", + "useOriginalDst": true + } + } } - } } diff --git a/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/inbound.test-server.golden.json b/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/inbound.test-server.golden.json index f329915e3e41..5115fd3f0cd8 100644 --- a/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/inbound.test-server.golden.json +++ b/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/inbound.test-server.golden.json @@ -1,511 +1,511 @@ { - "diff": [ - { - "op": "add", - "path": "/type.googleapis.com~1envoy.config.listener.v3.Listener/inbound:IP_REDACTED:80/filterChains/0/filters/0/typedConfig/accessLog", - "value": [ + "diff": [ { - "name": "envoy.access_loggers.file", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", - "logFormat": { - "textFormatSource": { - "inlineString": "[%START_TIME%]\n" - } - }, - "path": "/dev/stdout" - } - } - ] - } - ], - "xds": { - "type.googleapis.com/envoy.config.cluster.v3.Cluster": { - "envoyconfig_demo-client__kuma-3_msvc_3000": { - "name": "envoyconfig_demo-client__kuma-3_msvc_3000", - "type": "EDS", - "edsClusterConfig": { - "edsConfig": { - "ads": {}, - "resourceApiVersion": "V3" - } - }, - "typedExtensionProtocolOptions": { - "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { - "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", - "explicitHttpConfig": { - "http2ProtocolOptions": {} - } - } - } - }, - "envoyconfig_test-server__kuma-3_msvc_80": { - "name": "envoyconfig_test-server__kuma-3_msvc_80", - "type": "EDS", - "edsClusterConfig": { - "edsConfig": { - "ads": {}, - "resourceApiVersion": "V3" - } - }, - "typedExtensionProtocolOptions": { - "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { - "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", - "explicitHttpConfig": { - "http2ProtocolOptions": {} - } - } - } - }, - "inbound:passthrough:ipv4": { - "name": "inbound:passthrough:ipv4", - "altStatName": "inbound_passthrough_ipv4", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED", - "upstreamBindConfig": { - "sourceAddress": { - "address": "IP_REDACTED", - "portValue": 0 - } - } - }, - "inbound:passthrough:ipv6": { - "name": "inbound:passthrough:ipv6", - "altStatName": "inbound_passthrough_ipv6", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED", - "upstreamBindConfig": { - "sourceAddress": { - "address": "IP_REDACTED", - "portValue": 0 - } - } - }, - "localhost:8080": { - "name": "localhost:8080", - "altStatName": "localhost_8080", - "type": "STATIC", - "connectTimeout": "10s", - "loadAssignment": { - "clusterName": "localhost:8080", - "endpoints": [ - { - "lbEndpoints": [ + "op": "add", + "path": "/type.googleapis.com~1envoy.config.listener.v3.Listener/inbound:IP_REDACTED:80/filterChains/0/filters/0/typedConfig/accessLog", + "value": [ { - "endpoint": { - "address": { - "socketAddress": { + "name": "envoy.access_loggers.file", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", + "logFormat": { + "textFormatSource": { + "inlineString": "[%START_TIME%]\n" + } + }, + "path": "/dev/stdout" + } + } + ] + } + ], + "xds": { + "type.googleapis.com/envoy.config.cluster.v3.Cluster": { + "envoyconfig_demo-client__kuma-3_msvc_3000": { + "edsClusterConfig": { + "edsConfig": { + "ads": {}, + "resourceApiVersion": "V3" + } + }, + "name": "envoyconfig_demo-client__kuma-3_msvc_3000", + "type": "EDS", + "typedExtensionProtocolOptions": { + "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { + "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", + "explicitHttpConfig": { + "http2ProtocolOptions": {} + } + } + } + }, + "envoyconfig_test-server__kuma-3_msvc_80": { + "edsClusterConfig": { + "edsConfig": { + "ads": {}, + "resourceApiVersion": "V3" + } + }, + "name": "envoyconfig_test-server__kuma-3_msvc_80", + "type": "EDS", + "typedExtensionProtocolOptions": { + "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { + "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", + "explicitHttpConfig": { + "http2ProtocolOptions": {} + } + } + } + }, + "inbound:passthrough:ipv4": { + "altStatName": "inbound_passthrough_ipv4", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "inbound:passthrough:ipv4", + "type": "ORIGINAL_DST", + "upstreamBindConfig": { + "sourceAddress": { "address": "IP_REDACTED", - "portValue": 8080 - } + "portValue": 0 } - } } - ] + }, + "inbound:passthrough:ipv6": { + "altStatName": "inbound_passthrough_ipv6", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "inbound:passthrough:ipv6", + "type": "ORIGINAL_DST", + "upstreamBindConfig": { + "sourceAddress": { + "address": "IP_REDACTED", + "portValue": 0 + } + } + }, + "localhost:8080": { + "altStatName": "localhost_8080", + "connectTimeout": "10s", + "loadAssignment": { + "clusterName": "localhost:8080", + "endpoints": [ + { + "lbEndpoints": [ + { + "endpoint": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 8080 + } + } + } + } + ] + } + ] + }, + "name": "localhost:8080", + "type": "STATIC", + "typedExtensionProtocolOptions": { + "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { + "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", + "commonHttpProtocolOptions": { + "idleTimeout": "7200s" + }, + "explicitHttpConfig": { + "httpProtocolOptions": {} + } + } + }, + "upstreamBindConfig": { + "sourceAddress": { + "address": "IP_REDACTED", + "portValue": 0 + } + } + }, + "outbound:passthrough:ipv4": { + "altStatName": "outbound_passthrough_ipv4", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "outbound:passthrough:ipv4", + "type": "ORIGINAL_DST" + }, + "outbound:passthrough:ipv6": { + "altStatName": "outbound_passthrough_ipv6", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "outbound:passthrough:ipv6", + "type": "ORIGINAL_DST" } - ] }, - "typedExtensionProtocolOptions": { - "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { - "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", - "commonHttpProtocolOptions": { - "idleTimeout": "7200s" + "type.googleapis.com/envoy.config.endpoint.v3.ClusterLoadAssignment": { + "envoyconfig_demo-client__kuma-3_msvc_3000": { + "clusterName": "envoyconfig_demo-client__kuma-3_msvc_3000", + "endpoints": [ + { + "lbEndpoints": [ + { + "endpoint": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 3000 + } + } + }, + "loadBalancingWeight": 1, + "metadata": { + "filterMetadata": { + "envoy.lb": { + "kuma.io/zone": "kuma-3", + "team": "client-owners" + }, + "envoy.transport_socket_match": { + "kuma.io/zone": "kuma-3", + "team": "client-owners" + } + } + } + } + ], + "locality": { + "zone": "kuma-3" + } + } + ] }, - "explicitHttpConfig": { - "httpProtocolOptions": {} + "envoyconfig_test-server__kuma-3_msvc_80": { + "clusterName": "envoyconfig_test-server__kuma-3_msvc_80", + "endpoints": [ + { + "lbEndpoints": [ + { + "endpoint": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 80 + } + } + }, + "loadBalancingWeight": 1, + "metadata": { + "filterMetadata": { + "envoy.lb": { + "instance": "1", + "kuma.io/protocol": "http", + "kuma.io/zone": "kuma-3", + "team": "server-owners", + "version": "v1" + }, + "envoy.transport_socket_match": { + "instance": "1", + "kuma.io/protocol": "http", + "kuma.io/zone": "kuma-3", + "team": "server-owners", + "version": "v1" + } + } + } + } + ], + "locality": { + "zone": "kuma-3" + } + } + ] } - } }, - "upstreamBindConfig": { - "sourceAddress": { - "address": "IP_REDACTED", - "portValue": 0 - } - } - }, - "outbound:passthrough:ipv4": { - "name": "outbound:passthrough:ipv4", - "altStatName": "outbound_passthrough_ipv4", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED" - }, - "outbound:passthrough:ipv6": { - "name": "outbound:passthrough:ipv6", - "altStatName": "outbound_passthrough_ipv6", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED" - } - }, - "type.googleapis.com/envoy.config.endpoint.v3.ClusterLoadAssignment": { - "envoyconfig_demo-client__kuma-3_msvc_3000": { - "clusterName": "envoyconfig_demo-client__kuma-3_msvc_3000", - "endpoints": [ - { - "locality": { - "zone": "kuma-3" - }, - "lbEndpoints": [ - { - "endpoint": { - "address": { + "type.googleapis.com/envoy.config.listener.v3.Listener": { + "inbound:IP_REDACTED:80": { + "address": { "socketAddress": { - "address": "IP_REDACTED", - "portValue": 3000 + "address": "IP_REDACTED", + "portValue": 80 } - } }, + "bindToPort": false, + "enableReusePort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.http_connection_manager", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager", + "accessLog": [ + { + "name": "envoy.access_loggers.file", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", + "logFormat": { + "textFormatSource": { + "inlineString": "[%START_TIME%]\n" + } + }, + "path": "/dev/stdout" + } + } + ], + "commonHttpProtocolOptions": { + "idleTimeout": "7200s" + }, + "forwardClientCertDetails": "SANITIZE_SET", + "httpFilters": [ + { + "name": "envoy.filters.http.router", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.http.router.v3.Router" + } + } + ], + "routeConfig": { + "name": "inbound:test-server", + "requestHeadersToRemove": [ + "x-kuma-tags" + ], + "validateClusters": false, + "virtualHosts": [ + { + "domains": [ + "*" + ], + "name": "test-server", + "routes": [ + { + "match": { + "prefix": "/" + }, + "route": { + "cluster": "localhost:8080", + "timeout": "0s" + } + } + ] + } + ] + }, + "setCurrentClientCertDetails": { + "uri": true + }, + "statPrefix": "localhost_8080", + "streamIdleTimeout": "3600s" + } + } + ] + } + ], "metadata": { - "filterMetadata": { - "envoy.lb": { - "kuma.io/zone": "kuma-3", - "team": "client-owners" - }, - "envoy.transport_socket_match": { - "kuma.io/zone": "kuma-3", - "team": "client-owners" + "filterMetadata": { + "io.kuma.tags": { + "instance": "1", + "kuma.io/protocol": "http", + "kuma.io/service": "test-server", + "kuma.io/zone": "kuma-3", + "team": "server-owners", + "version": "v1" + } } - } }, - "loadBalancingWeight": 1 - } - ] - } - ] - }, - "envoyconfig_test-server__kuma-3_msvc_80": { - "clusterName": "envoyconfig_test-server__kuma-3_msvc_80", - "endpoints": [ - { - "locality": { - "zone": "kuma-3" + "name": "inbound:IP_REDACTED:80", + "trafficDirection": "INBOUND" }, - "lbEndpoints": [ - { - "endpoint": { - "address": { + "inbound:passthrough:ipv4": { + "address": { "socketAddress": { - "address": "IP_REDACTED", - "portValue": 80 + "address": "IP_REDACTED", + "portValue": 15006 } - } }, - "metadata": { - "filterMetadata": { - "envoy.lb": { - "instance": "1", - "kuma.io/protocol": "http", - "kuma.io/zone": "kuma-3", - "team": "server-owners", - "version": "v1" - }, - "envoy.transport_socket_match": { - "instance": "1", - "kuma.io/protocol": "http", - "kuma.io/zone": "kuma-3", - "team": "server-owners", - "version": "v1" + "enableReusePort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "inbound:passthrough:ipv4", + "statPrefix": "inbound_passthrough_ipv4" + } + } + ] + } + ], + "name": "inbound:passthrough:ipv4", + "trafficDirection": "INBOUND", + "useOriginalDst": true + }, + "inbound:passthrough:ipv6": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15006 } - } }, - "loadBalancingWeight": 1 - } - ] - } - ] - } - }, - "type.googleapis.com/envoy.config.listener.v3.Listener": { - "inbound:IP_REDACTED:80": { - "name": "inbound:IP_REDACTED:80", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 80 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.http_connection_manager", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager", - "statPrefix": "localhost_8080", - "routeConfig": { - "name": "inbound:test-server", - "virtualHosts": [ - { - "name": "test-server", - "domains": [ - "*" - ], - "routes": [ - { - "match": { - "prefix": "/" - }, - "route": { - "cluster": "localhost:8080", - "timeout": "0s" + "enableReusePort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "inbound:passthrough:ipv6", + "statPrefix": "inbound_passthrough_ipv6" + } } - } ] - } - ], - "requestHeadersToRemove": [ - "x-kuma-tags" - ], - "validateClusters": false - }, - "httpFilters": [ + } + ], + "name": "inbound:passthrough:ipv6", + "trafficDirection": "INBOUND", + "useOriginalDst": true + }, + "outbound:IP_REDACTED:3000": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 3000 + } + }, + "bindToPort": false, + "filterChains": [ { - "name": "envoy.filters.http.router", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.http.router.v3.Router" - } + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "envoyconfig_demo-client__kuma-3_msvc_3000", + "statPrefix": "envoyconfig_demo-client__kuma-3_msvc_3000" + } + } + ] + } + ], + "metadata": { + "filterMetadata": { + "io.kuma.tags": {} + } + }, + "name": "outbound:IP_REDACTED:3000", + "trafficDirection": "OUTBOUND" + }, + "outbound:IP_REDACTED:80": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 80 } - ], - "commonHttpProtocolOptions": { - "idleTimeout": "7200s" - }, - "streamIdleTimeout": "3600s", - "accessLog": [ + }, + "bindToPort": false, + "filterChains": [ { - "name": "envoy.access_loggers.file", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", - "path": "/dev/stdout", - "logFormat": { - "textFormatSource": { - "inlineString": "[%START_TIME%]\n" - } - } - } + "filters": [ + { + "name": "envoy.filters.network.http_connection_manager", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager", + "httpFilters": [ + { + "name": "envoy.filters.http.router", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.http.router.v3.Router" + } + } + ], + "normalizePath": true, + "routeConfig": { + "name": "outbound:envoyconfig_test-server__kuma-3_msvc_80", + "validateClusters": false, + "virtualHosts": [ + { + "domains": [ + "*" + ], + "name": "envoyconfig_test-server__kuma-3_msvc_80", + "routes": [ + { + "match": { + "prefix": "/" + }, + "name": "9Zuf5Tg79OuZcQITwBbQykxAk2u4fRKrwYn3//AL4Yo=", + "route": { + "cluster": "envoyconfig_test-server__kuma-3_msvc_80", + "timeout": "0s" + } + } + ] + } + ] + }, + "statPrefix": "envoyconfig_test-server__kuma-3_msvc_80" + } + } + ] } - ], - "forwardClientCertDetails": "SANITIZE_SET", - "setCurrentClientCertDetails": { - "uri": true - } - } - } - ] - } - ], - "metadata": { - "filterMetadata": { - "io.kuma.tags": { - "instance": "1", - "kuma.io/protocol": "http", - "kuma.io/service": "test-server", - "kuma.io/zone": "kuma-3", - "team": "server-owners", - "version": "v1" - } - } - }, - "trafficDirection": "INBOUND", - "enableReusePort": false, - "bindToPort": false - }, - "inbound:passthrough:ipv4": { - "name": "inbound:passthrough:ipv4", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15006 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "inbound_passthrough_ipv4", - "cluster": "inbound:passthrough:ipv4" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "INBOUND", - "enableReusePort": false - }, - "inbound:passthrough:ipv6": { - "name": "inbound:passthrough:ipv6", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15006 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "inbound_passthrough_ipv6", - "cluster": "inbound:passthrough:ipv6" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "INBOUND", - "enableReusePort": false - }, - "outbound:IP_REDACTED:3000": { - "name": "outbound:IP_REDACTED:3000", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 3000 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "envoyconfig_demo-client__kuma-3_msvc_3000", - "cluster": "envoyconfig_demo-client__kuma-3_msvc_3000" - } - } - ] - } - ], - "metadata": { - "filterMetadata": { - "io.kuma.tags": {} - } - }, - "trafficDirection": "OUTBOUND", - "bindToPort": false - }, - "outbound:IP_REDACTED:80": { - "name": "outbound:IP_REDACTED:80", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 80 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.http_connection_manager", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager", - "statPrefix": "envoyconfig_test-server__kuma-3_msvc_80", - "routeConfig": { - "name": "outbound:envoyconfig_test-server__kuma-3_msvc_80", - "virtualHosts": [ - { - "name": "envoyconfig_test-server__kuma-3_msvc_80", - "domains": [ - "*" - ], - "routes": [ - { - "name": "9Zuf5Tg79OuZcQITwBbQykxAk2u4fRKrwYn3//AL4Yo=", - "match": { - "prefix": "/" - }, - "route": { - "cluster": "envoyconfig_test-server__kuma-3_msvc_80", - "timeout": "0s" + ], + "metadata": { + "filterMetadata": { + "io.kuma.tags": {} + } + }, + "name": "outbound:IP_REDACTED:80", + "trafficDirection": "OUTBOUND" + }, + "outbound:passthrough:ipv4": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15001 + } + }, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "outbound:passthrough:ipv4", + "statPrefix": "outbound_passthrough_ipv4" + } } - } ] - } - ], - "validateClusters": false - }, - "httpFilters": [ + } + ], + "name": "outbound:passthrough:ipv4", + "trafficDirection": "OUTBOUND", + "useOriginalDst": true + }, + "outbound:passthrough:ipv6": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15001 + } + }, + "filterChains": [ { - "name": "envoy.filters.http.router", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.http.router.v3.Router" - } + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "outbound:passthrough:ipv6", + "statPrefix": "outbound_passthrough_ipv6" + } + } + ] } - ], - "normalizePath": true - } - } - ] - } - ], - "metadata": { - "filterMetadata": { - "io.kuma.tags": {} - } - }, - "trafficDirection": "OUTBOUND", - "bindToPort": false - }, - "outbound:passthrough:ipv4": { - "name": "outbound:passthrough:ipv4", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15001 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "outbound_passthrough_ipv4", - "cluster": "outbound:passthrough:ipv4" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "OUTBOUND" - }, - "outbound:passthrough:ipv6": { - "name": "outbound:passthrough:ipv6", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15001 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "outbound_passthrough_ipv6", - "cluster": "outbound:passthrough:ipv6" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "OUTBOUND" - } + ], + "name": "outbound:passthrough:ipv6", + "trafficDirection": "OUTBOUND", + "useOriginalDst": true + } + } } - } } diff --git a/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/outbound.demo-client.golden.json b/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/outbound.demo-client.golden.json index 0bd5f85e6a82..b283aa9cafdc 100644 --- a/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/outbound.demo-client.golden.json +++ b/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/outbound.demo-client.golden.json @@ -1,467 +1,467 @@ { - "diff": [ - { - "op": "add", - "path": "/type.googleapis.com~1envoy.config.listener.v3.Listener/outbound:IP_REDACTED:80/filterChains/0/filters/0/typedConfig/accessLog", - "value": [ + "diff": [ { - "name": "envoy.access_loggers.file", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", - "logFormat": { - "jsonFormat": { - "Destination": "%test-server%", - "HeaderCamel": "%%REQ(X-Test)%%", - "HeaderCrazy": "%%REQ(X-TeSt)%%", - "HeaderLower": "%%REQ(x-test)%%", - "Source": "%demo-client%", - "Start": "%%START_TIME(%%s)%%" - } - }, - "path": "/dev/stdout" - } - } - ] - } - ], - "xds": { - "type.googleapis.com/envoy.config.cluster.v3.Cluster": { - "envoyconfig_demo-client__kuma-3_msvc_3000": { - "name": "envoyconfig_demo-client__kuma-3_msvc_3000", - "type": "EDS", - "edsClusterConfig": { - "edsConfig": { - "ads": {}, - "resourceApiVersion": "V3" - } - }, - "typedExtensionProtocolOptions": { - "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { - "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", - "explicitHttpConfig": { - "http2ProtocolOptions": {} - } - } - } - }, - "envoyconfig_test-server__kuma-3_msvc_80": { - "name": "envoyconfig_test-server__kuma-3_msvc_80", - "type": "EDS", - "edsClusterConfig": { - "edsConfig": { - "ads": {}, - "resourceApiVersion": "V3" - } - }, - "typedExtensionProtocolOptions": { - "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { - "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", - "explicitHttpConfig": { - "http2ProtocolOptions": {} - } - } - } - }, - "inbound:passthrough:ipv4": { - "name": "inbound:passthrough:ipv4", - "altStatName": "inbound_passthrough_ipv4", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED", - "upstreamBindConfig": { - "sourceAddress": { - "address": "IP_REDACTED", - "portValue": 0 - } - } - }, - "inbound:passthrough:ipv6": { - "name": "inbound:passthrough:ipv6", - "altStatName": "inbound_passthrough_ipv6", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED", - "upstreamBindConfig": { - "sourceAddress": { - "address": "IP_REDACTED", - "portValue": 0 - } - } - }, - "localhost:3000": { - "name": "localhost:3000", - "altStatName": "localhost_3000", - "type": "STATIC", - "connectTimeout": "10s", - "loadAssignment": { - "clusterName": "localhost:3000", - "endpoints": [ - { - "lbEndpoints": [ + "op": "add", + "path": "/type.googleapis.com~1envoy.config.listener.v3.Listener/outbound:IP_REDACTED:80/filterChains/0/filters/0/typedConfig/accessLog", + "value": [ { - "endpoint": { - "address": { - "socketAddress": { + "name": "envoy.access_loggers.file", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", + "logFormat": { + "jsonFormat": { + "Destination": "%test-server%", + "HeaderCamel": "%%REQ(X-Test)%%", + "HeaderCrazy": "%%REQ(X-TeSt)%%", + "HeaderLower": "%%REQ(x-test)%%", + "Source": "%demo-client%", + "Start": "%%START_TIME(%%s)%%" + } + }, + "path": "/dev/stdout" + } + } + ] + } + ], + "xds": { + "type.googleapis.com/envoy.config.cluster.v3.Cluster": { + "envoyconfig_demo-client__kuma-3_msvc_3000": { + "edsClusterConfig": { + "edsConfig": { + "ads": {}, + "resourceApiVersion": "V3" + } + }, + "name": "envoyconfig_demo-client__kuma-3_msvc_3000", + "type": "EDS", + "typedExtensionProtocolOptions": { + "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { + "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", + "explicitHttpConfig": { + "http2ProtocolOptions": {} + } + } + } + }, + "envoyconfig_test-server__kuma-3_msvc_80": { + "edsClusterConfig": { + "edsConfig": { + "ads": {}, + "resourceApiVersion": "V3" + } + }, + "name": "envoyconfig_test-server__kuma-3_msvc_80", + "type": "EDS", + "typedExtensionProtocolOptions": { + "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { + "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", + "explicitHttpConfig": { + "http2ProtocolOptions": {} + } + } + } + }, + "inbound:passthrough:ipv4": { + "altStatName": "inbound_passthrough_ipv4", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "inbound:passthrough:ipv4", + "type": "ORIGINAL_DST", + "upstreamBindConfig": { + "sourceAddress": { "address": "IP_REDACTED", - "portValue": 3000 - } + "portValue": 0 + } + } + }, + "inbound:passthrough:ipv6": { + "altStatName": "inbound_passthrough_ipv6", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "inbound:passthrough:ipv6", + "type": "ORIGINAL_DST", + "upstreamBindConfig": { + "sourceAddress": { + "address": "IP_REDACTED", + "portValue": 0 + } + } + }, + "localhost:3000": { + "altStatName": "localhost_3000", + "connectTimeout": "10s", + "loadAssignment": { + "clusterName": "localhost:3000", + "endpoints": [ + { + "lbEndpoints": [ + { + "endpoint": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 3000 + } + } + } + } + ] + } + ] + }, + "name": "localhost:3000", + "type": "STATIC", + "upstreamBindConfig": { + "sourceAddress": { + "address": "IP_REDACTED", + "portValue": 0 } - } } - ] + }, + "outbound:passthrough:ipv4": { + "altStatName": "outbound_passthrough_ipv4", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "outbound:passthrough:ipv4", + "type": "ORIGINAL_DST" + }, + "outbound:passthrough:ipv6": { + "altStatName": "outbound_passthrough_ipv6", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "outbound:passthrough:ipv6", + "type": "ORIGINAL_DST" } - ] }, - "upstreamBindConfig": { - "sourceAddress": { - "address": "IP_REDACTED", - "portValue": 0 - } - } - }, - "outbound:passthrough:ipv4": { - "name": "outbound:passthrough:ipv4", - "altStatName": "outbound_passthrough_ipv4", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED" - }, - "outbound:passthrough:ipv6": { - "name": "outbound:passthrough:ipv6", - "altStatName": "outbound_passthrough_ipv6", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED" - } - }, - "type.googleapis.com/envoy.config.endpoint.v3.ClusterLoadAssignment": { - "envoyconfig_demo-client__kuma-3_msvc_3000": { - "clusterName": "envoyconfig_demo-client__kuma-3_msvc_3000", - "endpoints": [ - { - "locality": { - "zone": "kuma-3" + "type.googleapis.com/envoy.config.endpoint.v3.ClusterLoadAssignment": { + "envoyconfig_demo-client__kuma-3_msvc_3000": { + "clusterName": "envoyconfig_demo-client__kuma-3_msvc_3000", + "endpoints": [ + { + "lbEndpoints": [ + { + "endpoint": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 3000 + } + } + }, + "loadBalancingWeight": 1, + "metadata": { + "filterMetadata": { + "envoy.lb": { + "kuma.io/zone": "kuma-3", + "team": "client-owners" + }, + "envoy.transport_socket_match": { + "kuma.io/zone": "kuma-3", + "team": "client-owners" + } + } + } + } + ], + "locality": { + "zone": "kuma-3" + } + } + ] }, - "lbEndpoints": [ - { - "endpoint": { - "address": { + "envoyconfig_test-server__kuma-3_msvc_80": { + "clusterName": "envoyconfig_test-server__kuma-3_msvc_80", + "endpoints": [ + { + "lbEndpoints": [ + { + "endpoint": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 80 + } + } + }, + "loadBalancingWeight": 1, + "metadata": { + "filterMetadata": { + "envoy.lb": { + "instance": "1", + "kuma.io/protocol": "http", + "kuma.io/zone": "kuma-3", + "team": "server-owners", + "version": "v1" + }, + "envoy.transport_socket_match": { + "instance": "1", + "kuma.io/protocol": "http", + "kuma.io/zone": "kuma-3", + "team": "server-owners", + "version": "v1" + } + } + } + } + ], + "locality": { + "zone": "kuma-3" + } + } + ] + } + }, + "type.googleapis.com/envoy.config.listener.v3.Listener": { + "inbound:IP_REDACTED:3000": { + "address": { "socketAddress": { - "address": "IP_REDACTED", - "portValue": 3000 + "address": "IP_REDACTED", + "portValue": 3000 } - } }, + "bindToPort": false, + "enableReusePort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "localhost:3000", + "idleTimeout": "7200s", + "statPrefix": "localhost_3000" + } + } + ] + } + ], "metadata": { - "filterMetadata": { - "envoy.lb": { - "kuma.io/zone": "kuma-3", - "team": "client-owners" - }, - "envoy.transport_socket_match": { - "kuma.io/zone": "kuma-3", - "team": "client-owners" + "filterMetadata": { + "io.kuma.tags": { + "kuma.io/service": "demo-client", + "kuma.io/zone": "kuma-3", + "team": "client-owners" + } } - } }, - "loadBalancingWeight": 1 - } - ] - } - ] - }, - "envoyconfig_test-server__kuma-3_msvc_80": { - "clusterName": "envoyconfig_test-server__kuma-3_msvc_80", - "endpoints": [ - { - "locality": { - "zone": "kuma-3" + "name": "inbound:IP_REDACTED:3000", + "trafficDirection": "INBOUND" + }, + "inbound:passthrough:ipv4": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15006 + } + }, + "enableReusePort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "inbound:passthrough:ipv4", + "statPrefix": "inbound_passthrough_ipv4" + } + } + ] + } + ], + "name": "inbound:passthrough:ipv4", + "trafficDirection": "INBOUND", + "useOriginalDst": true + }, + "inbound:passthrough:ipv6": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15006 + } + }, + "enableReusePort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "inbound:passthrough:ipv6", + "statPrefix": "inbound_passthrough_ipv6" + } + } + ] + } + ], + "name": "inbound:passthrough:ipv6", + "trafficDirection": "INBOUND", + "useOriginalDst": true }, - "lbEndpoints": [ - { - "endpoint": { - "address": { + "outbound:IP_REDACTED:3000": { + "address": { "socketAddress": { - "address": "IP_REDACTED", - "portValue": 80 + "address": "IP_REDACTED", + "portValue": 3000 } - } }, + "bindToPort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "envoyconfig_demo-client__kuma-3_msvc_3000", + "statPrefix": "envoyconfig_demo-client__kuma-3_msvc_3000" + } + } + ] + } + ], "metadata": { - "filterMetadata": { - "envoy.lb": { - "instance": "1", - "kuma.io/protocol": "http", - "kuma.io/zone": "kuma-3", - "team": "server-owners", - "version": "v1" - }, - "envoy.transport_socket_match": { - "instance": "1", - "kuma.io/protocol": "http", - "kuma.io/zone": "kuma-3", - "team": "server-owners", - "version": "v1" + "filterMetadata": { + "io.kuma.tags": {} } - } }, - "loadBalancingWeight": 1 - } - ] - } - ] - } - }, - "type.googleapis.com/envoy.config.listener.v3.Listener": { - "inbound:IP_REDACTED:3000": { - "name": "inbound:IP_REDACTED:3000", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 3000 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "localhost_3000", - "cluster": "localhost:3000", - "idleTimeout": "7200s" - } - } - ] - } - ], - "metadata": { - "filterMetadata": { - "io.kuma.tags": { - "kuma.io/service": "demo-client", - "kuma.io/zone": "kuma-3", - "team": "client-owners" - } - } - }, - "trafficDirection": "INBOUND", - "enableReusePort": false, - "bindToPort": false - }, - "inbound:passthrough:ipv4": { - "name": "inbound:passthrough:ipv4", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15006 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "inbound_passthrough_ipv4", - "cluster": "inbound:passthrough:ipv4" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "INBOUND", - "enableReusePort": false - }, - "inbound:passthrough:ipv6": { - "name": "inbound:passthrough:ipv6", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15006 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "inbound_passthrough_ipv6", - "cluster": "inbound:passthrough:ipv6" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "INBOUND", - "enableReusePort": false - }, - "outbound:IP_REDACTED:3000": { - "name": "outbound:IP_REDACTED:3000", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 3000 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "envoyconfig_demo-client__kuma-3_msvc_3000", - "cluster": "envoyconfig_demo-client__kuma-3_msvc_3000" - } - } - ] - } - ], - "metadata": { - "filterMetadata": { - "io.kuma.tags": {} - } - }, - "trafficDirection": "OUTBOUND", - "bindToPort": false - }, - "outbound:IP_REDACTED:80": { - "name": "outbound:IP_REDACTED:80", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 80 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.http_connection_manager", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager", - "statPrefix": "envoyconfig_test-server__kuma-3_msvc_80", - "routeConfig": { - "name": "outbound:envoyconfig_test-server__kuma-3_msvc_80", - "virtualHosts": [ - { - "name": "envoyconfig_test-server__kuma-3_msvc_80", - "domains": [ - "*" - ], - "routes": [ - { - "name": "9Zuf5Tg79OuZcQITwBbQykxAk2u4fRKrwYn3//AL4Yo=", - "match": { - "prefix": "/" - }, - "route": { - "cluster": "envoyconfig_test-server__kuma-3_msvc_80", - "timeout": "0s" + "name": "outbound:IP_REDACTED:3000", + "trafficDirection": "OUTBOUND" + }, + "outbound:IP_REDACTED:80": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 80 + } + }, + "bindToPort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.http_connection_manager", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager", + "accessLog": [ + { + "name": "envoy.access_loggers.file", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", + "logFormat": { + "jsonFormat": { + "Destination": "%test-server%", + "HeaderCamel": "%%REQ(X-Test)%%", + "HeaderCrazy": "%%REQ(X-TeSt)%%", + "HeaderLower": "%%REQ(x-test)%%", + "Source": "%demo-client%", + "Start": "%%START_TIME(%%s)%%" + } + }, + "path": "/dev/stdout" + } + } + ], + "httpFilters": [ + { + "name": "envoy.filters.http.router", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.http.router.v3.Router" + } + } + ], + "normalizePath": true, + "routeConfig": { + "name": "outbound:envoyconfig_test-server__kuma-3_msvc_80", + "validateClusters": false, + "virtualHosts": [ + { + "domains": [ + "*" + ], + "name": "envoyconfig_test-server__kuma-3_msvc_80", + "routes": [ + { + "match": { + "prefix": "/" + }, + "name": "9Zuf5Tg79OuZcQITwBbQykxAk2u4fRKrwYn3//AL4Yo=", + "route": { + "cluster": "envoyconfig_test-server__kuma-3_msvc_80", + "timeout": "0s" + } + } + ] + } + ] + }, + "statPrefix": "envoyconfig_test-server__kuma-3_msvc_80" + } } - } ] - } - ], - "validateClusters": false - }, - "httpFilters": [ + } + ], + "metadata": { + "filterMetadata": { + "io.kuma.tags": {} + } + }, + "name": "outbound:IP_REDACTED:80", + "trafficDirection": "OUTBOUND" + }, + "outbound:passthrough:ipv4": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15001 + } + }, + "filterChains": [ { - "name": "envoy.filters.http.router", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.http.router.v3.Router" - } + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "outbound:passthrough:ipv4", + "statPrefix": "outbound_passthrough_ipv4" + } + } + ] + } + ], + "name": "outbound:passthrough:ipv4", + "trafficDirection": "OUTBOUND", + "useOriginalDst": true + }, + "outbound:passthrough:ipv6": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15001 } - ], - "accessLog": [ + }, + "filterChains": [ { - "name": "envoy.access_loggers.file", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", - "path": "/dev/stdout", - "logFormat": { - "jsonFormat": { - "Destination": "%test-server%", - "HeaderCamel": "%%REQ(X-Test)%%", - "HeaderCrazy": "%%REQ(X-TeSt)%%", - "HeaderLower": "%%REQ(x-test)%%", - "Source": "%demo-client%", - "Start": "%%START_TIME(%%s)%%" - } - } - } + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "outbound:passthrough:ipv6", + "statPrefix": "outbound_passthrough_ipv6" + } + } + ] } - ], - "normalizePath": true - } - } - ] - } - ], - "metadata": { - "filterMetadata": { - "io.kuma.tags": {} - } - }, - "trafficDirection": "OUTBOUND", - "bindToPort": false - }, - "outbound:passthrough:ipv4": { - "name": "outbound:passthrough:ipv4", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15001 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "outbound_passthrough_ipv4", - "cluster": "outbound:passthrough:ipv4" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "OUTBOUND" - }, - "outbound:passthrough:ipv6": { - "name": "outbound:passthrough:ipv6", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15001 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "outbound_passthrough_ipv6", - "cluster": "outbound:passthrough:ipv6" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "OUTBOUND" - } + ], + "name": "outbound:passthrough:ipv6", + "trafficDirection": "OUTBOUND", + "useOriginalDst": true + } + } } - } } diff --git a/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/outbound.test-server.golden.json b/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/outbound.test-server.golden.json index 737a15bf6612..fbed1a6009af 100644 --- a/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/outbound.test-server.golden.json +++ b/test/e2e_env/universal/envoyconfig/testdata/meshaccesslog/outbound.test-server.golden.json @@ -1,521 +1,521 @@ { - "diff": [ - { - "op": "add", - "path": "/type.googleapis.com~1envoy.config.listener.v3.Listener/outbound:IP_REDACTED:80/filterChains/0/filters/0/typedConfig/accessLog", - "value": [ + "diff": [ { - "name": "envoy.access_loggers.file", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", - "logFormat": { - "jsonFormat": { - "Destination": "%test-server%", - "HeaderCamel": "%%REQ(X-Test)%%", - "HeaderCrazy": "%%REQ(X-TeSt)%%", - "HeaderLower": "%%REQ(x-test)%%", - "Source": "%test-server%", - "Start": "%%START_TIME(%%s)%%" - } - }, - "path": "/dev/stdout" - } - } - ] - } - ], - "xds": { - "type.googleapis.com/envoy.config.cluster.v3.Cluster": { - "envoyconfig_demo-client__kuma-3_msvc_3000": { - "name": "envoyconfig_demo-client__kuma-3_msvc_3000", - "type": "EDS", - "edsClusterConfig": { - "edsConfig": { - "ads": {}, - "resourceApiVersion": "V3" - } - }, - "typedExtensionProtocolOptions": { - "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { - "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", - "explicitHttpConfig": { - "http2ProtocolOptions": {} - } - } - } - }, - "envoyconfig_test-server__kuma-3_msvc_80": { - "name": "envoyconfig_test-server__kuma-3_msvc_80", - "type": "EDS", - "edsClusterConfig": { - "edsConfig": { - "ads": {}, - "resourceApiVersion": "V3" - } - }, - "typedExtensionProtocolOptions": { - "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { - "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", - "explicitHttpConfig": { - "http2ProtocolOptions": {} - } - } - } - }, - "inbound:passthrough:ipv4": { - "name": "inbound:passthrough:ipv4", - "altStatName": "inbound_passthrough_ipv4", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED", - "upstreamBindConfig": { - "sourceAddress": { - "address": "IP_REDACTED", - "portValue": 0 - } - } - }, - "inbound:passthrough:ipv6": { - "name": "inbound:passthrough:ipv6", - "altStatName": "inbound_passthrough_ipv6", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED", - "upstreamBindConfig": { - "sourceAddress": { - "address": "IP_REDACTED", - "portValue": 0 - } - } - }, - "localhost:8080": { - "name": "localhost:8080", - "altStatName": "localhost_8080", - "type": "STATIC", - "connectTimeout": "10s", - "loadAssignment": { - "clusterName": "localhost:8080", - "endpoints": [ - { - "lbEndpoints": [ + "op": "add", + "path": "/type.googleapis.com~1envoy.config.listener.v3.Listener/outbound:IP_REDACTED:80/filterChains/0/filters/0/typedConfig/accessLog", + "value": [ { - "endpoint": { - "address": { - "socketAddress": { + "name": "envoy.access_loggers.file", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", + "logFormat": { + "jsonFormat": { + "Destination": "%test-server%", + "HeaderCamel": "%%REQ(X-Test)%%", + "HeaderCrazy": "%%REQ(X-TeSt)%%", + "HeaderLower": "%%REQ(x-test)%%", + "Source": "%test-server%", + "Start": "%%START_TIME(%%s)%%" + } + }, + "path": "/dev/stdout" + } + } + ] + } + ], + "xds": { + "type.googleapis.com/envoy.config.cluster.v3.Cluster": { + "envoyconfig_demo-client__kuma-3_msvc_3000": { + "edsClusterConfig": { + "edsConfig": { + "ads": {}, + "resourceApiVersion": "V3" + } + }, + "name": "envoyconfig_demo-client__kuma-3_msvc_3000", + "type": "EDS", + "typedExtensionProtocolOptions": { + "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { + "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", + "explicitHttpConfig": { + "http2ProtocolOptions": {} + } + } + } + }, + "envoyconfig_test-server__kuma-3_msvc_80": { + "edsClusterConfig": { + "edsConfig": { + "ads": {}, + "resourceApiVersion": "V3" + } + }, + "name": "envoyconfig_test-server__kuma-3_msvc_80", + "type": "EDS", + "typedExtensionProtocolOptions": { + "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { + "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", + "explicitHttpConfig": { + "http2ProtocolOptions": {} + } + } + } + }, + "inbound:passthrough:ipv4": { + "altStatName": "inbound_passthrough_ipv4", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "inbound:passthrough:ipv4", + "type": "ORIGINAL_DST", + "upstreamBindConfig": { + "sourceAddress": { "address": "IP_REDACTED", - "portValue": 8080 - } + "portValue": 0 } - } } - ] + }, + "inbound:passthrough:ipv6": { + "altStatName": "inbound_passthrough_ipv6", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "inbound:passthrough:ipv6", + "type": "ORIGINAL_DST", + "upstreamBindConfig": { + "sourceAddress": { + "address": "IP_REDACTED", + "portValue": 0 + } + } + }, + "localhost:8080": { + "altStatName": "localhost_8080", + "connectTimeout": "10s", + "loadAssignment": { + "clusterName": "localhost:8080", + "endpoints": [ + { + "lbEndpoints": [ + { + "endpoint": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 8080 + } + } + } + } + ] + } + ] + }, + "name": "localhost:8080", + "type": "STATIC", + "typedExtensionProtocolOptions": { + "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { + "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", + "commonHttpProtocolOptions": { + "idleTimeout": "7200s" + }, + "explicitHttpConfig": { + "httpProtocolOptions": {} + } + } + }, + "upstreamBindConfig": { + "sourceAddress": { + "address": "IP_REDACTED", + "portValue": 0 + } + } + }, + "outbound:passthrough:ipv4": { + "altStatName": "outbound_passthrough_ipv4", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "outbound:passthrough:ipv4", + "type": "ORIGINAL_DST" + }, + "outbound:passthrough:ipv6": { + "altStatName": "outbound_passthrough_ipv6", + "connectTimeout": "5s", + "lbPolicy": "CLUSTER_PROVIDED", + "name": "outbound:passthrough:ipv6", + "type": "ORIGINAL_DST" } - ] }, - "typedExtensionProtocolOptions": { - "envoy.extensions.upstreams.http.v3.HttpProtocolOptions": { - "@type": "type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions", - "commonHttpProtocolOptions": { - "idleTimeout": "7200s" + "type.googleapis.com/envoy.config.endpoint.v3.ClusterLoadAssignment": { + "envoyconfig_demo-client__kuma-3_msvc_3000": { + "clusterName": "envoyconfig_demo-client__kuma-3_msvc_3000", + "endpoints": [ + { + "lbEndpoints": [ + { + "endpoint": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 3000 + } + } + }, + "loadBalancingWeight": 1, + "metadata": { + "filterMetadata": { + "envoy.lb": { + "kuma.io/zone": "kuma-3", + "team": "client-owners" + }, + "envoy.transport_socket_match": { + "kuma.io/zone": "kuma-3", + "team": "client-owners" + } + } + } + } + ], + "locality": { + "zone": "kuma-3" + } + } + ] }, - "explicitHttpConfig": { - "httpProtocolOptions": {} + "envoyconfig_test-server__kuma-3_msvc_80": { + "clusterName": "envoyconfig_test-server__kuma-3_msvc_80", + "endpoints": [ + { + "lbEndpoints": [ + { + "endpoint": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 80 + } + } + }, + "loadBalancingWeight": 1, + "metadata": { + "filterMetadata": { + "envoy.lb": { + "instance": "1", + "kuma.io/protocol": "http", + "kuma.io/zone": "kuma-3", + "team": "server-owners", + "version": "v1" + }, + "envoy.transport_socket_match": { + "instance": "1", + "kuma.io/protocol": "http", + "kuma.io/zone": "kuma-3", + "team": "server-owners", + "version": "v1" + } + } + } + } + ], + "locality": { + "zone": "kuma-3" + } + } + ] } - } }, - "upstreamBindConfig": { - "sourceAddress": { - "address": "IP_REDACTED", - "portValue": 0 - } - } - }, - "outbound:passthrough:ipv4": { - "name": "outbound:passthrough:ipv4", - "altStatName": "outbound_passthrough_ipv4", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED" - }, - "outbound:passthrough:ipv6": { - "name": "outbound:passthrough:ipv6", - "altStatName": "outbound_passthrough_ipv6", - "type": "ORIGINAL_DST", - "connectTimeout": "5s", - "lbPolicy": "CLUSTER_PROVIDED" - } - }, - "type.googleapis.com/envoy.config.endpoint.v3.ClusterLoadAssignment": { - "envoyconfig_demo-client__kuma-3_msvc_3000": { - "clusterName": "envoyconfig_demo-client__kuma-3_msvc_3000", - "endpoints": [ - { - "locality": { - "zone": "kuma-3" - }, - "lbEndpoints": [ - { - "endpoint": { - "address": { + "type.googleapis.com/envoy.config.listener.v3.Listener": { + "inbound:IP_REDACTED:80": { + "address": { "socketAddress": { - "address": "IP_REDACTED", - "portValue": 3000 + "address": "IP_REDACTED", + "portValue": 80 } - } }, + "bindToPort": false, + "enableReusePort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.http_connection_manager", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager", + "commonHttpProtocolOptions": { + "idleTimeout": "7200s" + }, + "forwardClientCertDetails": "SANITIZE_SET", + "httpFilters": [ + { + "name": "envoy.filters.http.router", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.http.router.v3.Router" + } + } + ], + "routeConfig": { + "name": "inbound:test-server", + "requestHeadersToRemove": [ + "x-kuma-tags" + ], + "validateClusters": false, + "virtualHosts": [ + { + "domains": [ + "*" + ], + "name": "test-server", + "routes": [ + { + "match": { + "prefix": "/" + }, + "route": { + "cluster": "localhost:8080", + "timeout": "0s" + } + } + ] + } + ] + }, + "setCurrentClientCertDetails": { + "uri": true + }, + "statPrefix": "localhost_8080", + "streamIdleTimeout": "3600s" + } + } + ] + } + ], "metadata": { - "filterMetadata": { - "envoy.lb": { - "kuma.io/zone": "kuma-3", - "team": "client-owners" - }, - "envoy.transport_socket_match": { - "kuma.io/zone": "kuma-3", - "team": "client-owners" + "filterMetadata": { + "io.kuma.tags": { + "instance": "1", + "kuma.io/protocol": "http", + "kuma.io/service": "test-server", + "kuma.io/zone": "kuma-3", + "team": "server-owners", + "version": "v1" + } } - } }, - "loadBalancingWeight": 1 - } - ] - } - ] - }, - "envoyconfig_test-server__kuma-3_msvc_80": { - "clusterName": "envoyconfig_test-server__kuma-3_msvc_80", - "endpoints": [ - { - "locality": { - "zone": "kuma-3" + "name": "inbound:IP_REDACTED:80", + "trafficDirection": "INBOUND" }, - "lbEndpoints": [ - { - "endpoint": { - "address": { + "inbound:passthrough:ipv4": { + "address": { "socketAddress": { - "address": "IP_REDACTED", - "portValue": 80 + "address": "IP_REDACTED", + "portValue": 15006 } - } }, - "metadata": { - "filterMetadata": { - "envoy.lb": { - "instance": "1", - "kuma.io/protocol": "http", - "kuma.io/zone": "kuma-3", - "team": "server-owners", - "version": "v1" - }, - "envoy.transport_socket_match": { - "instance": "1", - "kuma.io/protocol": "http", - "kuma.io/zone": "kuma-3", - "team": "server-owners", - "version": "v1" + "enableReusePort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "inbound:passthrough:ipv4", + "statPrefix": "inbound_passthrough_ipv4" + } + } + ] + } + ], + "name": "inbound:passthrough:ipv4", + "trafficDirection": "INBOUND", + "useOriginalDst": true + }, + "inbound:passthrough:ipv6": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15006 } - } }, - "loadBalancingWeight": 1 - } - ] - } - ] - } - }, - "type.googleapis.com/envoy.config.listener.v3.Listener": { - "inbound:IP_REDACTED:80": { - "name": "inbound:IP_REDACTED:80", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 80 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.http_connection_manager", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager", - "statPrefix": "localhost_8080", - "routeConfig": { - "name": "inbound:test-server", - "virtualHosts": [ - { - "name": "test-server", - "domains": [ - "*" - ], - "routes": [ - { - "match": { - "prefix": "/" - }, - "route": { - "cluster": "localhost:8080", - "timeout": "0s" + "enableReusePort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "inbound:passthrough:ipv6", + "statPrefix": "inbound_passthrough_ipv6" + } } - } ] - } - ], - "requestHeadersToRemove": [ - "x-kuma-tags" - ], - "validateClusters": false - }, - "httpFilters": [ + } + ], + "name": "inbound:passthrough:ipv6", + "trafficDirection": "INBOUND", + "useOriginalDst": true + }, + "outbound:IP_REDACTED:3000": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 3000 + } + }, + "bindToPort": false, + "filterChains": [ { - "name": "envoy.filters.http.router", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.http.router.v3.Router" - } + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "envoyconfig_demo-client__kuma-3_msvc_3000", + "statPrefix": "envoyconfig_demo-client__kuma-3_msvc_3000" + } + } + ] } - ], - "commonHttpProtocolOptions": { - "idleTimeout": "7200s" - }, - "streamIdleTimeout": "3600s", - "forwardClientCertDetails": "SANITIZE_SET", - "setCurrentClientCertDetails": { - "uri": true - } - } - } - ] - } - ], - "metadata": { - "filterMetadata": { - "io.kuma.tags": { - "instance": "1", - "kuma.io/protocol": "http", - "kuma.io/service": "test-server", - "kuma.io/zone": "kuma-3", - "team": "server-owners", - "version": "v1" - } - } - }, - "trafficDirection": "INBOUND", - "enableReusePort": false, - "bindToPort": false - }, - "inbound:passthrough:ipv4": { - "name": "inbound:passthrough:ipv4", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15006 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "inbound_passthrough_ipv4", - "cluster": "inbound:passthrough:ipv4" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "INBOUND", - "enableReusePort": false - }, - "inbound:passthrough:ipv6": { - "name": "inbound:passthrough:ipv6", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15006 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "inbound_passthrough_ipv6", - "cluster": "inbound:passthrough:ipv6" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "INBOUND", - "enableReusePort": false - }, - "outbound:IP_REDACTED:3000": { - "name": "outbound:IP_REDACTED:3000", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 3000 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "envoyconfig_demo-client__kuma-3_msvc_3000", - "cluster": "envoyconfig_demo-client__kuma-3_msvc_3000" - } - } - ] - } - ], - "metadata": { - "filterMetadata": { - "io.kuma.tags": {} - } - }, - "trafficDirection": "OUTBOUND", - "bindToPort": false - }, - "outbound:IP_REDACTED:80": { - "name": "outbound:IP_REDACTED:80", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 80 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.http_connection_manager", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager", - "statPrefix": "envoyconfig_test-server__kuma-3_msvc_80", - "routeConfig": { - "name": "outbound:envoyconfig_test-server__kuma-3_msvc_80", - "virtualHosts": [ - { - "name": "envoyconfig_test-server__kuma-3_msvc_80", - "domains": [ - "*" - ], - "routes": [ - { - "name": "9Zuf5Tg79OuZcQITwBbQykxAk2u4fRKrwYn3//AL4Yo=", - "match": { - "prefix": "/" - }, - "route": { - "cluster": "envoyconfig_test-server__kuma-3_msvc_80", - "timeout": "0s" + ], + "metadata": { + "filterMetadata": { + "io.kuma.tags": {} + } + }, + "name": "outbound:IP_REDACTED:3000", + "trafficDirection": "OUTBOUND" + }, + "outbound:IP_REDACTED:80": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 80 + } + }, + "bindToPort": false, + "filterChains": [ + { + "filters": [ + { + "name": "envoy.filters.network.http_connection_manager", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager", + "accessLog": [ + { + "name": "envoy.access_loggers.file", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", + "logFormat": { + "jsonFormat": { + "Destination": "%test-server%", + "HeaderCamel": "%%REQ(X-Test)%%", + "HeaderCrazy": "%%REQ(X-TeSt)%%", + "HeaderLower": "%%REQ(x-test)%%", + "Source": "%test-server%", + "Start": "%%START_TIME(%%s)%%" + } + }, + "path": "/dev/stdout" + } + } + ], + "httpFilters": [ + { + "name": "envoy.filters.http.router", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.http.router.v3.Router" + } + } + ], + "normalizePath": true, + "routeConfig": { + "name": "outbound:envoyconfig_test-server__kuma-3_msvc_80", + "validateClusters": false, + "virtualHosts": [ + { + "domains": [ + "*" + ], + "name": "envoyconfig_test-server__kuma-3_msvc_80", + "routes": [ + { + "match": { + "prefix": "/" + }, + "name": "9Zuf5Tg79OuZcQITwBbQykxAk2u4fRKrwYn3//AL4Yo=", + "route": { + "cluster": "envoyconfig_test-server__kuma-3_msvc_80", + "timeout": "0s" + } + } + ] + } + ] + }, + "statPrefix": "envoyconfig_test-server__kuma-3_msvc_80" + } } - } ] - } - ], - "validateClusters": false - }, - "httpFilters": [ + } + ], + "metadata": { + "filterMetadata": { + "io.kuma.tags": {} + } + }, + "name": "outbound:IP_REDACTED:80", + "trafficDirection": "OUTBOUND" + }, + "outbound:passthrough:ipv4": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15001 + } + }, + "filterChains": [ { - "name": "envoy.filters.http.router", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.http.router.v3.Router" - } + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "outbound:passthrough:ipv4", + "statPrefix": "outbound_passthrough_ipv4" + } + } + ] + } + ], + "name": "outbound:passthrough:ipv4", + "trafficDirection": "OUTBOUND", + "useOriginalDst": true + }, + "outbound:passthrough:ipv6": { + "address": { + "socketAddress": { + "address": "IP_REDACTED", + "portValue": 15001 } - ], - "accessLog": [ + }, + "filterChains": [ { - "name": "envoy.access_loggers.file", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog", - "path": "/dev/stdout", - "logFormat": { - "jsonFormat": { - "Destination": "%test-server%", - "HeaderCamel": "%%REQ(X-Test)%%", - "HeaderCrazy": "%%REQ(X-TeSt)%%", - "HeaderLower": "%%REQ(x-test)%%", - "Source": "%test-server%", - "Start": "%%START_TIME(%%s)%%" - } - } - } + "filters": [ + { + "name": "envoy.filters.network.tcp_proxy", + "typedConfig": { + "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", + "cluster": "outbound:passthrough:ipv6", + "statPrefix": "outbound_passthrough_ipv6" + } + } + ] } - ], - "normalizePath": true - } - } - ] - } - ], - "metadata": { - "filterMetadata": { - "io.kuma.tags": {} - } - }, - "trafficDirection": "OUTBOUND", - "bindToPort": false - }, - "outbound:passthrough:ipv4": { - "name": "outbound:passthrough:ipv4", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15001 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "outbound_passthrough_ipv4", - "cluster": "outbound:passthrough:ipv4" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "OUTBOUND" - }, - "outbound:passthrough:ipv6": { - "name": "outbound:passthrough:ipv6", - "address": { - "socketAddress": { - "address": "IP_REDACTED", - "portValue": 15001 - } - }, - "filterChains": [ - { - "filters": [ - { - "name": "envoy.filters.network.tcp_proxy", - "typedConfig": { - "@type": "type.googleapis.com/envoy.extensions.filters.network.tcp_proxy.v3.TcpProxy", - "statPrefix": "outbound_passthrough_ipv6", - "cluster": "outbound:passthrough:ipv6" - } - } - ] - } - ], - "useOriginalDst": true, - "trafficDirection": "OUTBOUND" - } + ], + "name": "outbound:passthrough:ipv6", + "trafficDirection": "OUTBOUND", + "useOriginalDst": true + } + } } - } }