Documentation
¶
Overview ¶
Package core provides core application functionality including server setup and configuration.
Index ¶
- func InitDatabaseAPI() error
- func Load(configPath string) error
- func RunAPI(handler http.Handler) error
- func RunLanding(handler http.Handler) error
- func RunPlatform(handler http.Handler) error
- func SetupAPI(Static embed.FS) http.Handler
- func SetupLanding(Static embed.FS) http.Handler
- func SetupLogging() error
- func SetupPlatform(Static embed.FS) http.Handler
- type Database
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitDatabaseAPI ¶
func InitDatabaseAPI() error
InitDatabaseAPI initializes the database connection from configuration
func RunLanding ¶
RunLanding starts the HTTP server for the landing page with graceful shutdown support
func RunPlatform ¶
RunPlatform starts the HTTP server for the platform with graceful shutdown support
func SetupLanding ¶
SetupLanding creates and configures the HTTP server for the landing page
func SetupLogging ¶
func SetupLogging() error
SetupLogging configures the logging system based on viper configuration
Types ¶
type Database ¶
type Database struct {
Driver string `mapstructure:"driver"`
Host string `mapstructure:"host"`
Port int `mapstructure:"port"`
Username string `mapstructure:"username"`
Password string `mapstructure:"password"`
Database string `mapstructure:"database"`
MaxOpenConns int `mapstructure:"max_open_conns"`
MaxIdleConns int `mapstructure:"max_idle_conns"`
ConnMaxLifetime int `mapstructure:"conn_max_lifetime"`
// SQLite specific
DataSource string `mapstructure:"datasource"`
}
Database holds the database configuration
Click to show internal directories.
Click to hide internal directories.