diff options
author | Nick Thomas <nick@gitlab.com> | 2021-07-27 09:37:34 +0000 |
---|---|---|
committer | Nick Thomas <nick@gitlab.com> | 2021-07-27 09:37:34 +0000 |
commit | f9e7ffda68192d24ff26f0d5ff7fe70e376c32f2 (patch) | |
tree | 987108c203fe5583a82bdc44e6277ab6d11fe7af /internal | |
parent | 82a2153dcc093a99445aedd3734fe7ef868e3a4b (diff) | |
parent | 76260c3b48b08879e631a3e410b5db4e473653e0 (diff) | |
download | gitlab-shell-f9e7ffda68192d24ff26f0d5ff7fe70e376c32f2.tar.gz |
Merge branch 'sh-update-go-proxyproto' into 'main'
Update go-proxyproto to v0.6.0
See merge request gitlab-org/gitlab-shell!499
Diffstat (limited to 'internal')
-rw-r--r-- | internal/sshd/sshd.go | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/internal/sshd/sshd.go b/internal/sshd/sshd.go index 7f96bef..8b49712 100644 --- a/internal/sshd/sshd.go +++ b/internal/sshd/sshd.go @@ -29,6 +29,7 @@ const ( StatusReady StatusOnShutdown StatusClosed + ProxyHeaderTimeout = 90 * time.Second ) type Server struct { @@ -84,7 +85,10 @@ func (s *Server) listen() error { } if s.Config.Server.ProxyProtocol { - sshListener = &proxyproto.Listener{Listener: sshListener} + sshListener = &proxyproto.Listener{ + Listener: sshListener, + ReadHeaderTimeout: ProxyHeaderTimeout, + } log.Info("Proxy protocol is enabled") } |