feat(proxyproto): add proxy protocol support (#7738)

Signed-off-by: Adphi <philippe.adrien.nousse@gmail.com>
This commit is contained in:
Adphi
2026-02-11 02:14:05 +01:00
committed by GitHub
parent a100d0cca4
commit e9c0db32dc
15 changed files with 389 additions and 3 deletions

View File

@@ -10,6 +10,8 @@ import (
"github.com/coredns/caddy"
"github.com/coredns/coredns/plugin"
"github.com/coredns/coredns/request"
"github.com/pires/go-proxyproto"
)
// Config configuration for a single server.
@@ -66,6 +68,11 @@ type Config struct {
// This is nil if not specified, allowing for a default to be used.
MaxQUICWorkerPoolSize *int
// ProxyProtoConnPolicy is the function that will be used to
// configure the PROXY protocol settings on listeners.
// If nil, PROXY protocol is disabled.
ProxyProtoConnPolicy proxyproto.ConnPolicyFunc
// MaxGRPCStreams defines the maximum number of concurrent streams per gRPC connection.
// This is nil if not specified, allowing for a default to be used.
MaxGRPCStreams *int