package config // Configuration type Config struct { Server *Server Database *Database Auth *Auth Log *Log } // Server configuration type Server struct { Host string `toml:"host"` Port int `toml:"port"` ReadTimeout int `toml:"read_timeout"` WriteTimeout int `toml:"write_timeout"` } // Database configuration type Database struct { Driver string `toml:"driver"` URL string `toml:"url"` Max int `toml:"max"` Idle int `toml:"idle"` } // Auth configuration type Auth struct { Secret string `toml:"secret"` Register bool `toml:"register"` Cost int `toml:"cost"` } // Log configuration type Log struct { Level string `toml:"level"` }