Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Server ServerConfig `json:"server"`
Security SecurityConfig `json:"security"`
Libvirt LibvirtConfig `json:"libvirt"`
Logging LoggingConfig `json:"logging"`
}
Config represents the application configuration
func LoadConfig ¶
LoadConfig loads configuration from file and environment variables
func (*Config) GetServerAddress ¶
GetServerAddress returns the full server address
func (*Config) SaveConfig ¶
SaveConfig saves the configuration to a file
type LibvirtConfig ¶
type LibvirtConfig struct {
URI string `json:"uri"`
ISOPool string `json:"iso_pool"`
TemplatePool string `json:"template_pool"`
ImagePoolPath string `json:"image_pool_path"`
}
LibvirtConfig represents libvirt-related configuration
type LoggingConfig ¶
type LoggingConfig struct {
Level string `json:"level"` // DEBUG, INFO, WARN, ERROR, FATAL
Format string `json:"format"` // json, text
}
LoggingConfig represents logging configuration
type SecurityConfig ¶
type SecurityConfig struct {
RateLimitRequests int `json:"rate_limit_requests"` // requests per minute
RateLimitBurst int `json:"rate_limit_burst"` // burst size
PassphraseHash string `json:"passphrase_hash"` // bcrypt hash of web UI passphrase
}
SecurityConfig represents security-related configuration
Click to show internal directories.
Click to hide internal directories.