authelia/internal/configuration/schema/telemetry.go
James Elliott 001589cd6d
feat(metrics): implement prometheus metrics (#3234)
Adds ability to record metrics and gather them for Prometheus.
2022-06-14 17:20:13 +10:00

24 lines
559 B
Go

package schema
import (
"net"
)
// TelemetryConfig represents the telemetry config.
type TelemetryConfig struct {
Metrics TelemetryMetricsConfig `koanf:"metrics"`
}
// TelemetryMetricsConfig represents the telemetry metrics config.
type TelemetryMetricsConfig struct {
Enabled bool `koanf:"enabled"`
Address Address `koanf:"address"`
}
// DefaultTelemetryConfig is the default telemetry configuration.
var DefaultTelemetryConfig = TelemetryConfig{
Metrics: TelemetryMetricsConfig{
Address: NewAddress("tcp", net.ParseIP("0.0.0.0"), 9959),
},
}