This commit is contained in:
crusader 2018-04-12 18:54:44 +09:00
parent 796da7bbfe
commit e45555a9b6
4 changed files with 21 additions and 4 deletions

9
core/config/proxy.go Normal file
View File

@ -0,0 +1,9 @@
package config
type Proxy struct {
Host string `json:"host" yaml:"host" toml:"host"`
Port int `json:"port" yaml:"port" toml:"port"`
UseAuth bool `default:"false" json:"useAuth" yaml:"useAuth" toml:"useAuth"`
User string `json:"user" yaml:"user" toml:"user"`
Password string `json:"password" yaml:"password" toml:"password"`
}

View File

@ -2,3 +2,4 @@ package: git.loafle.net/overflow/commons-go
import:
- package: github.com/google/gopacket
version: ^1.1.14
- package: git.loafle.net/commons/server-go

View File

@ -1,6 +1,6 @@
package config
type Account struct {
Name string `json:"name"`
APIKey string `json:"apiKey"`
Name string `required:"true" json:"name"`
APIKey string `required:"true" json:"apiKey"`
}

View File

@ -1,6 +1,13 @@
package config
import (
csswc "git.loafle.net/commons/server-go/socket/web/client"
"git.loafle.net/overflow/commons-go/core/config"
)
type Central struct {
Host string `json:"host"`
Port int `json:"port"`
Host string `required:"true" json:"host"`
Port int `required:"true" json:"port"`
Connector *csswc.Connectors `required:"true" json:"connector"`
Proxy *config.Proxy `json:"proxy"`
}