Documentation
¶
Index ¶
Constants ¶
View Source
const DefaultMigrateTable = "bingo_migration"
Variables ¶
This section is empty.
Functions ¶
func LoadConfig ¶
func LoadConfig(cfg string, data interface{})
LoadConfig reads in config file and ENV variables if set.
Types ¶
type Config ¶
type Config struct {
Version string `mapstructure:"version" json:"version" yaml:"version"`
RootPackage string `mapstructure:"rootPackage" json:"rootPackage" yaml:"rootPackage"`
Directory Directory `mapstructure:"directory" json:"directory" yaml:"directory"`
MysqlOptions *db.MySQLOptions `mapstructure:"mysql" json:"mysql" yaml:"mysql"`
Registries Registries `mapstructure:"registries" json:"registries" yaml:"registries"`
Migrate MigrateConfig `mapstructure:"migrate" json:"migrate" yaml:"migrate"`
}
func NewDefaultConfig ¶
func NewDefaultConfig() *Config
func (*Config) GetMigrateTable ¶ added in v1.5.2
type Directory ¶
type Directory struct {
CMD string `mapstructure:"cmd" json:"cmd" yaml:"cmd"`
Model string `mapstructure:"model" json:"model" yaml:"model"`
Store string `mapstructure:"store" json:"store" yaml:"store"`
Request string `mapstructure:"request" json:"request" yaml:"request"`
Biz string `mapstructure:"biz" json:"biz" yaml:"biz"`
Handler string `mapstructure:"handler" json:"handler" yaml:"handler"`
Middleware string `mapstructure:"middleware" json:"middleware" yaml:"middleware"`
Job string `mapstructure:"job" json:"job" yaml:"job"`
Migration string `mapstructure:"migration" json:"migration" yaml:"migration"`
Seeder string `mapstructure:"seeder" json:"seeder" yaml:"seeder"`
}
type MigrateConfig ¶ added in v1.5.2
type MigrateConfig struct {
Table string `mapstructure:"table" json:"table" yaml:"table"`
}
type Registries ¶ added in v0.1.7
Click to show internal directories.
Click to hide internal directories.