feat: add Logbull remote logging via slog handler, tee to stdout
This commit is contained in:
@@ -14,6 +14,7 @@ type Config struct {
|
||||
Redis RedisConfig `mapstructure:"redis"`
|
||||
SMTP SMTPConfig `mapstructure:"smtp"`
|
||||
RateLimit RateLimitConfig `mapstructure:"rate_limit"`
|
||||
Logbull LogbullConfig `mapstructure:"logbull"`
|
||||
}
|
||||
|
||||
type ServerConfig struct {
|
||||
@@ -57,6 +58,13 @@ type RateLimitConfig struct {
|
||||
Default int `mapstructure:"default"`
|
||||
}
|
||||
|
||||
type LogbullConfig struct {
|
||||
Host string `mapstructure:"host"`
|
||||
ProjectID string `mapstructure:"project_id"`
|
||||
APIKey string `mapstructure:"api_key"`
|
||||
LogLevel string `mapstructure:"log_level"`
|
||||
}
|
||||
|
||||
func Load(path string) (*Config, error) {
|
||||
v := viper.New()
|
||||
v.SetConfigFile(path)
|
||||
|
||||
Reference in New Issue
Block a user