You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: apps/nsqadmin/main.go
+3
Original file line number
Diff line number
Diff line change
@@ -47,14 +47,17 @@ var (
47
47
httpClientTLSKey=flagSet.String("http-client-tls-key", "", "path to key file for the HTTP client")
48
48
49
49
allowConfigFromCIDR=flagSet.String("allow-config-from-cidr", "127.0.0.1/8", "A CIDR from which to allow HTTP requests to the /config endpoint")
50
+
aclHttpHeader=flagSet.String("acl-http-header", "X-Forwarded-User", "HTTP header to check for authenticated admin users")
50
51
52
+
adminUsers= app.StringArray{}
51
53
nsqlookupdHTTPAddresses= app.StringArray{}
52
54
nsqdHTTPAddresses= app.StringArray{}
53
55
)
54
56
55
57
funcinit() {
56
58
flagSet.Var(&nsqlookupdHTTPAddresses, "lookupd-http-address", "lookupd HTTP address (may be given multiple times)")
57
59
flagSet.Var(&nsqdHTTPAddresses, "nsqd-http-address", "nsqd HTTP address (may be given multiple times)")
60
+
flagSet.Var(&adminUsers, "admin-user", "admin user (may be given multiple times; if specified, only these users will be able to perform privileged actions; acl-http-header is used to determine the authenticated user)")
0 commit comments