Documentation
¶
Overview ¶
Package config provides the configuration for the opampcommander application.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdminSettings ¶
type AdminSettings struct {
// Username is the username for the admin user.
Username string
// Password is the password for the admin user.
Password string
// Email is the email address for the admin user.
// This is used in jwt claims.
Email string
}
AdminSettings holds the configuration settings for admin authentication. This is used for basic authentication of the admin user.
type AuthSettings ¶
type AuthSettings struct {
// JWTSettings holds the configuration settings for JSON Web Tokens (JWT).
JWTSettings JWTSettings
// AdminSettings holds the configuration settings for admin authentication.
AdminSettings AdminSettings
// OAuthSettings holds the configuration settings for OAuth2 authentication.
OAuthSettings *OAuthSettings
}
AuthSettings holds the authentication settings for the application.
type JWTSettings ¶
type JWTSettings struct {
SigningKey string
Issuer string
Expiration time.Duration
Audience []string
}
JWTSettings holds the configuration settings for JSON Web Tokens (JWT).
type OAuthSettings ¶
type OAuthSettings struct {
// ClientID is the OAuth2 client ID for GitHub authentication.
ClientID string
// Secret is the OAuth2 client secret for GitHub authentication.
Secret string
// CallbackURL is the URL to which GitHub will redirect after authentication.
CallbackURL string
// JWTSettings holds the JWT configuration settings.
// This is used for the state parameter in OAuth2 authentication.
JWTSettings JWTSettings
}
OAuthSettings holds the configuration settings for GitHub OAuth2 authentication.
type ServerSettings ¶
type ServerSettings struct {
Address string
DatabaesEndpoints []string
LogLevel slog.Level
LogFormat LogFormat
AuthSettings *AuthSettings
}
ServerSettings is a struct that holds the server settings.
Click to show internal directories.
Click to hide internal directories.