From 51a9cc978311de9c65a2095983acf37f74447f71 Mon Sep 17 00:00:00 2001 From: Zakhar Bessarab Date: Fri, 7 Jul 2023 15:50:13 +0400 Subject: [PATCH] docs: make `httpAuth.*` flags description less ambiguous (#4588) * docs: make `httpAuth.*` flags description less ambiguous Currently, it may confuse users whether `httpAuth.*` flags are used by HTTP client or server configuration(see https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4586 for example). Signed-off-by: Zakhar Bessarab * docs: fix a typo Signed-off-by: Zakhar Bessarab --------- Signed-off-by: Zakhar Bessarab --- README.md | 4 ++-- app/vmagent/README.md | 4 ++-- app/vmalert/README.md | 4 ++-- app/vmauth/README.md | 4 ++-- app/vmbackup/README.md | 4 ++-- app/vmbackupmanager/README.md | 4 ++-- app/vmgateway/README.md | 4 ++-- app/vmrestore/README.md | 4 ++-- docs/Cluster-VictoriaMetrics.md | 12 ++++++------ docs/README.md | 4 ++-- docs/Single-server-VictoriaMetrics.md | 4 ++-- docs/VictoriaLogs/README.md | 6 +++--- docs/vmagent.md | 4 ++-- docs/vmalert.md | 4 ++-- docs/vmauth.md | 4 ++-- docs/vmbackup.md | 4 ++-- docs/vmbackupmanager.md | 4 ++-- docs/vmgateway.md | 4 ++-- docs/vmrestore.md | 4 ++-- lib/httpserver/httpserver.go | 4 ++-- 20 files changed, 45 insertions(+), 45 deletions(-) diff --git a/README.md b/README.md index b27215641c..5a250745c8 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 6f19238ed3..3814edd364 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 0b25c4a012..95923203c9 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 09e7293355..e359b21b87 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 f1c8635bb0..23e83e54ab 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 2ce104e1ca..599f1ba09d 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 1d165b1b86..2277b39b31 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 ce342157e9..f2b74a2c9a 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 4f6a9cedcb..9c537f9267 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 b69b5c2f9e..1959145f49 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 e57f10be18..a5957f9bee 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 25c0996fcc..a74051876f 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 d2e9a5d5bd..0a7eeedfb0 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 a914402a56..5c5888ec29 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 90164663e5..a86c8bb401 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 80930fc53b..3c8be70dd5 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 818f0f2c04..9f97cb227c 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 946a85c6f5..e6b84ea552 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 644f2ac5e0..f822bfd213 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 4f249208d0..9a9675bafc 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")