Files
nixcn-cms/config/types.go
2025-12-24 20:43:19 +08:00

39 lines
838 B
Go

package config
type config struct {
Server server `yaml:"server"`
Database database `yaml:"database"`
Email email `yaml:"email"`
Secrets secrets `yaml:"secrets"`
TTL ttl `yaml:"ttl"`
}
type server struct {
Address string `yaml:"address"`
DebugMode string `yaml:"debug_mode"`
FileLogger string `yaml:"file_logger"`
JwtSecret string `yaml:"jwt_secret"`
}
type database struct {
Type string `yaml:"type"`
Host string `yaml:"host"`
Name string `yaml:"name"`
Username string `yaml:"username"`
Password string `yaml:"password"`
}
type email struct {
ResendApiKey string `yaml:"resend_api_key"`
From string `yaml:"from"`
}
type secrets struct {
jwt string `yaml:"jwt"`
turnstile string `yaml:"turnstile"`
}
type ttl struct {
magic_token string `yaml:"magin_token"`
}