Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Db *gorm.DB
Functions ¶
func InitRedisDB ¶
func InitRedisDB(redis *RedisConfig)
Types ¶
type Config ¶
type Config struct { Server *serverModel `yaml:"server"` DB *DbConfig `yaml:"db"` Redis *RedisConfig `yaml:"redis"` }
func (*Config) ReadConfig ¶
type DbConfig ¶
type DbConfig struct { Host string `yaml:"host"` Port string `yaml:"port"` Username string `yaml:"username"` Password string `yaml:"password"` Database string `yaml:"database"` Charset string `yaml:"charset"` Category string `yaml:"category"` PrintSql bool `yaml:"sql"` TablePrefix string `yaml:"table_prefix"` DbPool *DbPool `yaml:"pool"` DbInit *DbInit `yaml:"init"` }
type RDBManager ¶
Click to show internal directories.
Click to hide internal directories.