From 9ab1f0f2ae5498a0a7608002a318ae8830fe078e Mon Sep 17 00:00:00 2001 From: Flynn Date: Thu, 20 Dec 2018 16:03:31 -0500 Subject: [PATCH] Configure use_proxy_proto correctly (fixes #1050). --- ambassador/ambassador/envoy/v2/v2listener.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ambassador/ambassador/envoy/v2/v2listener.py b/ambassador/ambassador/envoy/v2/v2listener.py index 9b6011656d..222d94d2b9 100644 --- a/ambassador/ambassador/envoy/v2/v2listener.py +++ b/ambassador/ambassador/envoy/v2/v2listener.py @@ -331,6 +331,9 @@ def __init__(self, config: 'V2Config', listener: IRListener) -> None: } ] + if self.use_proxy_proto is not None: + chain['use_proxy_proto'] = self.use_proxy_proto + self.update({ 'name': self.name, 'address': { @@ -438,7 +441,4 @@ def handle_sni(self, config: 'V2Config') -> None: if matched: chain['routes'].append(sni_route['route']) - if self.use_proxy_proto is not None: - chain['use_proxy_proto'] = self.use_proxy_proto - self.filter_chains.append(chain)