27 lines
521 B
Go
27 lines
521 B
Go
package models
|
|
|
|
type Sys struct {
|
|
Port int `yaml:"port"`
|
|
}
|
|
|
|
type DB struct {
|
|
Host string `yaml:"host"`
|
|
Port int `yaml:"port"`
|
|
User string `yaml:"user"`
|
|
Password string `yaml:"password"`
|
|
Database string `yaml:"database"`
|
|
}
|
|
|
|
type Redis struct {
|
|
Host string `yaml:"host"`
|
|
Port int `yaml:"port"`
|
|
Password string `yaml:"password"`
|
|
DB int `yaml:"db"`
|
|
}
|
|
|
|
type Config struct {
|
|
Sys Sys `yaml:"sys"`
|
|
DB DB `yaml:"db"`
|
|
Redis Redis `yaml:"redis"`
|
|
}
|