@@ -57,13 +57,19 @@ static_resources:
57
57
routes :
58
58
- match :
59
59
prefix : " /"
60
+ {{- if .envoy.dynamic_routing.enabled }}
60
61
typed_per_filter_config :
61
62
envoy.filters.http.dynamic_forward_proxy :
62
63
" @type " : type.googleapis.com/envoy.extensions.filters.http.dynamic_forward_proxy.v3.PerRouteConfig
63
64
host_rewrite_header : " x-model-host"
64
65
route :
65
66
cluster : dynamic_forward_proxy_cluster
66
67
timeout : {{ .envoy.grpc_route_timeout }}
68
+ {{- else }}
69
+ route :
70
+ cluster : triton_grpc_service
71
+ timeout : {{ .envoy.grpc_route_timeout }}
72
+ {{- end }}
67
73
68
74
http_filters :
69
75
{{- with .envoy.rate_limiter.prometheus_based }}
@@ -99,6 +105,7 @@ static_resources:
99
105
provider_name : provider_icecube
100
106
{{- end }}
101
107
{{- end }}
108
+ {{- if .envoy.dynamic_routing.enabled }}
102
109
- name : envoy.filters.http.dynamic_forward_proxy
103
110
typed_config :
104
111
" @type " : type.googleapis.com/envoy.extensions.filters.http.dynamic_forward_proxy.v3.FilterConfig
@@ -107,6 +114,7 @@ static_resources:
107
114
dns_lookup_family : ALL
108
115
dns_cache_circuit_breaker :
109
116
max_pending_requests : 1024
117
+ {{- end }}
110
118
- name : envoy.filters.http.router
111
119
typed_config :
112
120
" @type " : type.googleapis.com/envoy.extensions.filters.http.router.v3.Router
@@ -189,6 +197,7 @@ static_resources:
189
197
socket_address :
190
198
address : {{ .tritonName }}
191
199
port_value : {{ .tritonGrpcPort }}
200
+ {{- if .envoy.dynamic_routing.enabled }}
192
201
- name : dynamic_forward_proxy_cluster
193
202
connect_timeout : 2s
194
203
lb_policy : CLUSTER_PROVIDED
@@ -203,6 +212,7 @@ static_resources:
203
212
dns_lookup_family : ALL
204
213
dns_cache_circuit_breaker :
205
214
max_pending_requests : 1024
215
+ {{- end }}
206
216
{{- end }}
207
217
{{- end }}
208
218
0 commit comments