...
1 package webserver
2
3 const (
4 WebDisableAll string = "all"
5 WebDisableUI string = "ui"
6 )
7
8
9 type CmdOpts struct {
10 WebDisable string `long:"web-disable" mapstructure:"web-disable" description:"Disable REST API and/or web UI" env:"PW_WEBDISABLE" optional:"true" optional-value:"all" choice:"all" choice:"ui"`
11 WebAddr string `long:"web-addr" mapstructure:"web-addr" description:"TCP address in the form 'host:port' to listen on" default:":8080" env:"PW_WEBADDR"`
12 WebBasePath string `long:"web-base-path" mapstructure:"web-base-path" description:"Base path for web UI and API endpoints (e.g., 'pgwatch' for reverse proxy setups)" env:"PW_WEBBASEPATH"`
13 WebUser string `long:"web-user" mapstructure:"web-user" description:"Admin username" env:"PW_WEBUSER"`
14 WebPassword string `long:"web-password" mapstructure:"web-password" description:"Admin password" env:"PW_WEBPASSWORD"`
15 }
16