From 808f35709b91aa5aab45860cbce919561c98daff Mon Sep 17 00:00:00 2001 From: liuxiaolong <736321739@qq.com> Date: 星期三, 17 七月 2019 10:51:59 +0800 Subject: [PATCH] add weedfs config --- extend/config/config.go | 9 +++++++++ 1 files changed, 9 insertions(+), 0 deletions(-) diff --git a/extend/config/config.go b/extend/config/config.go index e3ca7ee..4b182ee 100644 --- a/extend/config/config.go +++ b/extend/config/config.go @@ -16,6 +16,14 @@ var Server = &server{} +type weedfs struct { + Ip string `mapstructure: "ip"` + UploadPort int `mapstructure: "uploadport"` + VisitPort int `mapstructure: "visitport"` +} + +var WeedFs = &weedfs{} + type redis struct { Host string `mapstructure:"host"` Port int `mapstructure:"port"` @@ -70,4 +78,5 @@ viper.UnmarshalKey("server", Server) viper.UnmarshalKey("redis", RedisConf) viper.UnmarshalKey("database", DBconf) + viper.UnmarshalKey("weedfs", WeedFs) } -- Gitblit v1.8.0