diff --git a/README.md b/README.md index b27215641..5a250745c 100644 --- a/README.md +++ b/README.md @@ -2289,9 +2289,9 @@ Pass `-help` to VictoriaMetrics in order to see the list of supported command-li -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address to listen for http connections. See also -httpListenAddr.useProxyProtocol (default ":8428") -httpListenAddr.useProxyProtocol diff --git a/app/vmagent/README.md b/app/vmagent/README.md index 6f19238ed..3814edd36 100644 --- a/app/vmagent/README.md +++ b/app/vmagent/README.md @@ -1226,9 +1226,9 @@ See the docs at https://docs.victoriametrics.com/vmagent.html . -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address to listen for http connections. Set this flag to empty value in order to disable listening on any port. This mode may be useful for running multiple vmagent instances on the same server. Note that /targets and /metrics pages aren't available if -httpListenAddr=''. See also -httpListenAddr.useProxyProtocol (default ":8429") -httpListenAddr.useProxyProtocol diff --git a/app/vmalert/README.md b/app/vmalert/README.md index 0b25c4a01..95923203c 100644 --- a/app/vmalert/README.md +++ b/app/vmalert/README.md @@ -1000,9 +1000,9 @@ The shortlist of configuration flags is the following: -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string Address to listen for http connections. See also -httpListenAddr.useProxyProtocol (default ":8880") -httpListenAddr.useProxyProtocol diff --git a/app/vmauth/README.md b/app/vmauth/README.md index 09e729335..e359b21b8 100644 --- a/app/vmauth/README.md +++ b/app/vmauth/README.md @@ -368,9 +368,9 @@ See the docs at https://docs.victoriametrics.com/vmauth.html . -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address to listen for http connections. See also -httpListenAddr.useProxyProtocol (default ":8427") -httpListenAddr.useProxyProtocol diff --git a/app/vmbackup/README.md b/app/vmbackup/README.md index f1c8635bb..23e83e54a 100644 --- a/app/vmbackup/README.md +++ b/app/vmbackup/README.md @@ -214,9 +214,9 @@ See [this article](https://medium.com/@valyala/speeding-up-backups-for-big-time- -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address for exporting metrics at /metrics page (default ":8420") -internStringCacheExpireDuration duration diff --git a/app/vmbackupmanager/README.md b/app/vmbackupmanager/README.md index 2ce104e1c..599f1ba09 100644 --- a/app/vmbackupmanager/README.md +++ b/app/vmbackupmanager/README.md @@ -447,9 +447,9 @@ command-line flags: -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string Address to listen for http connections (default ":8300") -internStringCacheExpireDuration duration diff --git a/app/vmgateway/README.md b/app/vmgateway/README.md index 1d165b1b8..2277b39b3 100644 --- a/app/vmgateway/README.md +++ b/app/vmgateway/README.md @@ -356,9 +356,9 @@ The shortlist of configuration flags include the following: -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address to listen for http connections. See also -httpListenAddr.useProxyProtocol (default ":8431") -httpListenAddr.useProxyProtocol diff --git a/app/vmrestore/README.md b/app/vmrestore/README.md index ce342157e..f2b74a2c9 100644 --- a/app/vmrestore/README.md +++ b/app/vmrestore/README.md @@ -118,9 +118,9 @@ i.e. the end result would be similar to [rsync --delete](https://askubuntu.com/q -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address for exporting metrics at /metrics page (default ":8421") -internStringCacheExpireDuration duration diff --git a/docs/Cluster-VictoriaMetrics.md b/docs/Cluster-VictoriaMetrics.md index 4f6a9cedc..9c537f926 100644 --- a/docs/Cluster-VictoriaMetrics.md +++ b/docs/Cluster-VictoriaMetrics.md @@ -869,9 +869,9 @@ Below is the output for `/path/to/vminsert -help`: -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string Address to listen for http connections. See also -httpListenAddr.useProxyProtocol (default ":8480") -httpListenAddr.useProxyProtocol @@ -1078,9 +1078,9 @@ Below is the output for `/path/to/vmselect -help`: -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string Address to listen for http connections. See also -httpListenAddr.useProxyProtocol (default ":8481") -httpListenAddr.useProxyProtocol @@ -1302,9 +1302,9 @@ Below is the output for `/path/to/vmstorage -help`: -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string Address to listen for http connections. See also -httpListenAddr.useProxyProtocol (default ":8482") -httpListenAddr.useProxyProtocol diff --git a/docs/README.md b/docs/README.md index b69b5c2f9..1959145f4 100644 --- a/docs/README.md +++ b/docs/README.md @@ -2292,9 +2292,9 @@ Pass `-help` to VictoriaMetrics in order to see the list of supported command-li -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address to listen for http connections. See also -httpListenAddr.useProxyProtocol (default ":8428") -httpListenAddr.useProxyProtocol diff --git a/docs/Single-server-VictoriaMetrics.md b/docs/Single-server-VictoriaMetrics.md index e57f10be1..a5957f9be 100644 --- a/docs/Single-server-VictoriaMetrics.md +++ b/docs/Single-server-VictoriaMetrics.md @@ -2300,9 +2300,9 @@ Pass `-help` to VictoriaMetrics in order to see the list of supported command-li -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address to listen for http connections. See also -httpListenAddr.useProxyProtocol (default ":8428") -httpListenAddr.useProxyProtocol diff --git a/docs/VictoriaLogs/README.md b/docs/VictoriaLogs/README.md index 25c0996fc..a74051876 100644 --- a/docs/VictoriaLogs/README.md +++ b/docs/VictoriaLogs/README.md @@ -158,9 +158,9 @@ Pass `-help` to VictoriaLogs in order to see the list of supported command-line -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address to listen for http connections. See also -httpListenAddr.useProxyProtocol (default ":9428") -httpListenAddr.useProxyProtocol @@ -245,4 +245,4 @@ Pass `-help` to VictoriaLogs in order to see the list of supported command-line -tlsMinVersion string Optional minimum TLS version to use for incoming requests over HTTPS if -tls is set. Supported values: TLS10, TLS11, TLS12, TLS13 -version -``` \ No newline at end of file +``` diff --git a/docs/vmagent.md b/docs/vmagent.md index d2e9a5d5b..0a7eeedfb 100644 --- a/docs/vmagent.md +++ b/docs/vmagent.md @@ -1237,9 +1237,9 @@ See the docs at https://docs.victoriametrics.com/vmagent.html . -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address to listen for http connections. Set this flag to empty value in order to disable listening on any port. This mode may be useful for running multiple vmagent instances on the same server. Note that /targets and /metrics pages aren't available if -httpListenAddr=''. See also -httpListenAddr.useProxyProtocol (default ":8429") -httpListenAddr.useProxyProtocol diff --git a/docs/vmalert.md b/docs/vmalert.md index a914402a5..5c5888ec2 100644 --- a/docs/vmalert.md +++ b/docs/vmalert.md @@ -1011,9 +1011,9 @@ The shortlist of configuration flags is the following: -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string Address to listen for http connections. See also -httpListenAddr.useProxyProtocol (default ":8880") -httpListenAddr.useProxyProtocol diff --git a/docs/vmauth.md b/docs/vmauth.md index 90164663e..a86c8bb40 100644 --- a/docs/vmauth.md +++ b/docs/vmauth.md @@ -379,9 +379,9 @@ See the docs at https://docs.victoriametrics.com/vmauth.html . -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address to listen for http connections. See also -httpListenAddr.useProxyProtocol (default ":8427") -httpListenAddr.useProxyProtocol diff --git a/docs/vmbackup.md b/docs/vmbackup.md index 80930fc53..3c8be70dd 100644 --- a/docs/vmbackup.md +++ b/docs/vmbackup.md @@ -225,9 +225,9 @@ See [this article](https://medium.com/@valyala/speeding-up-backups-for-big-time- -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address for exporting metrics at /metrics page (default ":8420") -internStringCacheExpireDuration duration diff --git a/docs/vmbackupmanager.md b/docs/vmbackupmanager.md index 818f0f2c0..9f97cb227 100644 --- a/docs/vmbackupmanager.md +++ b/docs/vmbackupmanager.md @@ -458,9 +458,9 @@ command-line flags: -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string Address to listen for http connections (default ":8300") -internStringCacheExpireDuration duration diff --git a/docs/vmgateway.md b/docs/vmgateway.md index 946a85c6f..e6b84ea55 100644 --- a/docs/vmgateway.md +++ b/docs/vmgateway.md @@ -367,9 +367,9 @@ The shortlist of configuration flags include the following: -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address to listen for http connections. See also -httpListenAddr.useProxyProtocol (default ":8431") -httpListenAddr.useProxyProtocol diff --git a/docs/vmrestore.md b/docs/vmrestore.md index 644f2ac5e..f822bfd21 100644 --- a/docs/vmrestore.md +++ b/docs/vmrestore.md @@ -129,9 +129,9 @@ i.e. the end result would be similar to [rsync --delete](https://askubuntu.com/q -http.shutdownDelay duration Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers -httpAuth.password string - Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty + Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty -httpAuth.username string - Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password + Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password -httpListenAddr string TCP address for exporting metrics at /metrics page (default ":8421") -internStringCacheExpireDuration duration diff --git a/lib/httpserver/httpserver.go b/lib/httpserver/httpserver.go index 4f249208d..9a9675baf 100644 --- a/lib/httpserver/httpserver.go +++ b/lib/httpserver/httpserver.go @@ -40,8 +40,8 @@ var ( pathPrefix = flag.String("http.pathPrefix", "", "An optional prefix to add to all the paths handled by http server. For example, if '-http.pathPrefix=/foo/bar' is set, "+ "then all the http requests will be handled on '/foo/bar/*' paths. This may be useful for proxied requests. "+ "See https://www.robustperception.io/using-external-urls-and-proxies-with-prometheus") - httpAuthUsername = flag.String("httpAuth.username", "", "Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password") - httpAuthPassword = flag.String("httpAuth.password", "", "Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty") + httpAuthUsername = flag.String("httpAuth.username", "", "Username for HTTP server's Basic Auth. The authentication is disabled if empty. See also -httpAuth.password") + httpAuthPassword = flag.String("httpAuth.password", "", "Password for HTTP server's Basic Auth. The authentication is disabled if -httpAuth.username is empty") metricsAuthKey = flag.String("metricsAuthKey", "", "Auth key for /metrics endpoint. It must be passed via authKey query arg. It overrides httpAuth.* settings") flagsAuthKey = flag.String("flagsAuthKey", "", "Auth key for /flags endpoint. It must be passed via authKey query arg. It overrides httpAuth.* settings") pprofAuthKey = flag.String("pprofAuthKey", "", "Auth key for /debug/pprof/* endpoints. It must be passed via authKey query arg. It overrides httpAuth.* settings")