You've already forked oauth2-proxy
mirror of
https://github.com/oauth2-proxy/oauth2-proxy.git
synced 2026-05-22 10:15:21 +02:00
Add DefaultUpstreamFlushInterval to replace magic time.Second value
This commit is contained in:
@@ -27,7 +27,7 @@ func NewLegacyOptions() *LegacyOptions {
|
||||
LegacyUpstreams: LegacyUpstreams{
|
||||
PassHostHeader: true,
|
||||
ProxyWebSockets: true,
|
||||
FlushInterval: time.Duration(1) * time.Second,
|
||||
FlushInterval: DefaultUpstreamFlushInterval,
|
||||
},
|
||||
|
||||
LegacyHeaders: LegacyHeaders{
|
||||
@@ -62,7 +62,7 @@ type LegacyUpstreams struct {
|
||||
func legacyUpstreamsFlagSet() *pflag.FlagSet {
|
||||
flagSet := pflag.NewFlagSet("upstreams", pflag.ExitOnError)
|
||||
|
||||
flagSet.Duration("flush-interval", time.Duration(1)*time.Second, "period between response flushing when streaming responses")
|
||||
flagSet.Duration("flush-interval", DefaultUpstreamFlushInterval, "period between response flushing when streaming responses")
|
||||
flagSet.Bool("pass-host-header", true, "pass the request Host Header to upstream")
|
||||
flagSet.Bool("proxy-websockets", true, "enables WebSocket proxying")
|
||||
flagSet.Bool("ssl-upstream-insecure-skip-verify", false, "skip validation of certificates presented when using HTTPS upstreams")
|
||||
|
||||
Reference in New Issue
Block a user