Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
// DebugPprof enables pprof endpoints for debugging and profiling.
DebugPprof bool `json:"debugPprof,omitzero"`
// EnableTrustedProxyCheck enables trusted proxy checks.
EnableTrustedProxyCheck bool `json:"enableTrustedProxyCheck,omitzero"`
// TrustedProxies is the list of trusted proxies.
// This only takes effect if EnableTrustedProxyCheck is true.
TrustedProxies []string `json:"trustedProxies,omitzero"`
// ProxyHeader is the header used to determine the client's IP address.
// If empty, the remote peer's address is used.
ProxyHeader string `json:"proxyHeader,omitzero"`
// ListenNetwork is the network type.
ListenNetwork string `json:"listenNetwork,omitzero"`
// ListenAddress is the address to listen on.
ListenAddress string `json:"listenAddress"`
// ListenMode optionally sets the file mode of the unix domain socket.
// It must be an octal number in a string (e.g., "0660").
ListenMode jsoncfg.FileMode `json:"listenMode,omitzero"`
// CertFile is the path to the certificate file.
// If empty, TLS is disabled.
CertFile string `json:"certFile,omitzero"`
// KeyFile is the path to the key file.
// This is required if CertFile is set.
KeyFile string `json:"keyFile,omitzero"`
// ClientCertFile is the path to the client certificate file.
// If empty, client certificate authentication is disabled.
ClientCertFile string `json:"clientCertFile,omitzero"`
// StaticPath is the path where static files are served from.
// If empty, static file serving is disabled.
StaticPath string `json:"staticPath,omitzero"`
// SecretPath adds a secret path prefix to all routes.
// If empty, no secret path is added.
SecretPath string `json:"secretPath,omitzero"`
// FiberConfigPath overrides the [fiber.Config] settings we use.
// If empty, no overrides are applied.
FiberConfigPath string `json:"fiberConfigPath,omitzero"`
// Admin is the configuration for the admin API.
Admin admin.Config `json:"admin,omitzero"`
// OpenProxySharing is the configuration for the Open Proxy Sharing API.
OpenProxySharing ops.Config `json:"openProxySharing,omitzero"`
}
Config stores the configuration for the RESTful API.
Click to show internal directories.
Click to hide internal directories.