feat: temp upload

This commit is contained in:
fallen-angle
2022-04-13 19:48:10 +08:00
parent 80ca1cd46e
commit fc347a4140
15 changed files with 155 additions and 8 deletions

48
global/config.go Normal file
View File

@@ -0,0 +1,48 @@
package global
type ServerConfig struct {
Listen string `yaml:"listen"`
Port int `yaml:"port"`
Name string `yaml:"name"`
Env string `yaml:"env"`
UrlPrefix string `yaml:"urlPrefix"`
LogPath string `yaml:"logPath"`
MySQL MySQLConfig `yaml:"mysql"`
Redis RedisConfig `yaml:"redis"`
Jwt JwtConfig `yaml:"jwt"`
Email EmailConfig `yaml:"email"`
Bos BosConfig `yaml:"bos"`
}
type MySQLConfig struct {
Host string `yaml:"host"`
Port int `yaml:"port"`
Username string `yaml:"username"`
Password string `yaml:"password"`
Database string `yaml:"database"`
}
type RedisConfig struct {
Host string `yaml:"host"`
Port int `yaml:"port"`
Password string `yaml:"password"`
}
type JwtConfig struct {
Secret string `yaml:"secret"`
RenewExpireDays uint `yaml:"renewExpireDays"`
RenewAheadDays uint `yaml:"renewAheadDays"`
}
type EmailConfig struct {
Host string `yaml:"host"`
Port int `yaml:"port"`
Account string `yaml:"account"`
Password string `yaml:"password"`
}
type BosConfig struct {
AccessKey string `yaml:"accessKey"`
SecretKey string `yaml:"secretKey"`
Domain string `yaml:"domain"`
}