Documentation
¶
Index ¶
Constants ¶
View Source
const ( AuthModeTurn = "turn" AuthModeAll = "all" AuthModeNone = "none" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct {
LogLevel LogLevel `default:"info" split_words:"true"`
ExternalIP string `split_words:"true"`
TLSCertFile string `split_words:"true"`
TLSKeyFile string `split_words:"true"`
ServerTLS bool `split_words:"true"`
ServerAddress string `default:"0.0.0.0:5050" split_words:"true"`
Secret []byte `split_words:"true"`
TurnAddress string `default:"0.0.0.0:3478" required:"true" split_words:"true"`
TurnStrictAuth bool `default:"true" split_words:"true"`
TurnPortRange string `split_words:"true"`
TrustProxyHeaders bool `split_words:"true"`
AuthMode string `default:"turn" split_words:"true"`
CorsAllowedOrigins []string `split_words:"true"`
UsersFile string `split_words:"true"`
Prometheus bool `split_words:"true"`
CheckOrigin func(string) bool `ignored:"true" json:"-"`
}
Config represents the application configuration.
type FutureLog ¶
FutureLog is an intermediate type for log messages. It is used before the config was loaded because without loaded config we do not know the log level, so we log these messages once the config was initialized.
type LogLevel ¶
LogLevel type that provides helper methods for decoding.
func (LogLevel) AsZeroLogLevel ¶
AsZeroLogLevel converts the LogLevel to a zerolog.Level.
Click to show internal directories.
Click to hide internal directories.