sunty
2019-10-30 a1ef2d42d320f075c75e8cef52a879114441c103
extend/config/config.go
@@ -1,10 +1,15 @@
package config
import (
   "github.com/spf13/viper"
   "log"
   "github.com/spf13/viper"
)
type threshold struct {
   Value int    `mapstructure: "value"`
   Color string `mapstructure: "color"`
}
type server struct {
   Runmode   string `mapstructure: "runmode"`
   JwtSecret string `mapstructure: "jwtSecret"`
@@ -20,6 +25,9 @@
   WebVersion string `mapstructure: "webVersion"`  //web版本
   ChannelCount string `mapstructure: "channelCount"`  //通道个数
   DiskCount string `mapstructure: "diskCount"`  //硬盘个数
   SudoPassword  string      `mapstructure: "sudoPassword"`
   SysThresholds []threshold `mapstructure: "sysThresholds"`
}
var Server = &server{}