Add AMap location and weather header with warm mini program theme
This commit is contained in:
@@ -9,7 +9,12 @@ import (
|
||||
"github.com/spf13/viper"
|
||||
)
|
||||
|
||||
type AMapConfig struct {
|
||||
Key string `mapstructure:"key"`
|
||||
}
|
||||
|
||||
type Config struct {
|
||||
AMap AMapConfig `mapstructure:"amap"`
|
||||
Server ServerConfig `mapstructure:"server"`
|
||||
Postgres PostgresConfig `mapstructure:"postgres"`
|
||||
MinIO MinIOConfig `mapstructure:"minio"`
|
||||
@@ -67,6 +72,7 @@ type AdminConfig struct {
|
||||
|
||||
func Load() (*Config, error) {
|
||||
v := viper.New()
|
||||
v.SetDefault("amap.key", "")
|
||||
v.SetDefault("server.port", 9090)
|
||||
v.SetDefault("server.mode", "debug")
|
||||
v.SetDefault("postgres.host", "192.168.100.127")
|
||||
|
||||
Reference in New Issue
Block a user