Skip to content

Commit 5e4979e

Browse files
committed
update nginx template for TLS passthrough (nginx#2166)
Update nginx template for TLS passthrough Problem: nginx configuration templates didn't support TLS passthrough Solution: I added a template setup fro stream servers
1 parent 3298bb9 commit 5e4979e

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

internal/mode/static/nginx/config/servers_template.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ server {
3535
{{- if $.IPFamily.IPv6 }}
3636
listen [::]:{{ $s.Listen }} ssl;
3737
{{- end }}
38+
3839
ssl_certificate {{ $s.SSL.Certificate }};
3940
ssl_certificate_key {{ $s.SSL.CertificateKey }};
4041

internal/mode/static/state/dataplane/configuration.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ const (
3030
func BuildConfiguration(
3131
ctx context.Context,
3232
g *graph.Graph,
33-
resolver resolver.ServiceResolver,
33+
serviceResolver resolver.ServiceResolver,
3434
generator policies.ConfigGenerator,
3535
configVersion int,
3636
) Configuration {
@@ -43,7 +43,7 @@ func BuildConfiguration(
4343
}
4444

4545
baseHTTPConfig := buildBaseHTTPConfig(g)
46-
upstreams := buildUpstreams(ctx, g.Gateway.Listeners, resolver, baseHTTPConfig.IPFamily)
46+
upstreams := buildUpstreams(ctx, g.Gateway.Listeners, serviceResolver, baseHTTPConfig.IPFamily)
4747
httpServers, sslServers := buildServers(g, generator)
4848
backendGroups := buildBackendGroups(append(httpServers, sslServers...))
4949
keyPairs := buildSSLKeyPairs(g.ReferencedSecrets, g.Gateway.Listeners)

0 commit comments

Comments
 (0)