ing
This commit is contained in:
parent
078d10a10e
commit
ae7d8a8d8c
12
modules/noauthprobe/config/config.go
Normal file
12
modules/noauthprobe/config/config.go
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
package config
|
||||||
|
|
||||||
|
import "git.loafle.net/overflow/overflow_commons_go/util"
|
||||||
|
|
||||||
|
const (
|
||||||
|
NoAuthProbeConfigFileName = "noauthprobe.json"
|
||||||
|
)
|
||||||
|
|
||||||
|
type NoAuthProbeConfig struct {
|
||||||
|
TempKey *string `json:"tempKey,omitempty" yaml:"tempKey" toml:"tempKey"`
|
||||||
|
DenyDate *util.Timestamp `json:"denyDate,omitempty" yaml:"denyDate" toml:"denyDate"`
|
||||||
|
}
|
21
modules/probe/config/config.go
Normal file
21
modules/probe/config/config.go
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
package config
|
||||||
|
|
||||||
|
const (
|
||||||
|
ConfigFileName = "config.json"
|
||||||
|
)
|
||||||
|
|
||||||
|
type Config struct {
|
||||||
|
Central CentralConfig `json:"central" yaml:"central" toml:"central"`
|
||||||
|
Probe ProbeConfig `json:"probe" yaml:"probe" toml:"probe"`
|
||||||
|
}
|
||||||
|
|
||||||
|
type CentralConfig struct {
|
||||||
|
URL string `required:"true" json:"url" yaml:"url" toml:"url"`
|
||||||
|
APIKey string `required:"true" json:"apiKey" yaml:"apiKey" toml:"apiKey"`
|
||||||
|
ReadBufferSize int `default:"8192" json:"readBufferSize" yaml:"readBufferSize" toml:"readBufferSize"`
|
||||||
|
WriteBufferSize int `default:"8192" json:"writeBufferSize" yaml:"writeBufferSize" toml:"writeBufferSize"`
|
||||||
|
}
|
||||||
|
|
||||||
|
type ProbeConfig struct {
|
||||||
|
Key *string `json:"key,omitempty" yaml:"key" toml:"key"`
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user