forked from fabiolb/fabio
-
Notifications
You must be signed in to change notification settings - Fork 0
/
default.go
52 lines (50 loc) · 914 Bytes
/
default.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
package config
import (
"runtime"
"time"
)
var Default = &Config{
Proxy: Proxy{
MaxConn: 10000,
Strategy: "rnd",
Matcher: "prefix",
NoRouteStatus: 404,
DialTimeout: 30 * time.Second,
LocalIP: LocalIPString(),
},
Registry: Registry{
Backend: "consul",
Consul: Consul{
Addr: "localhost:8500",
KVPath: "/fabio/config",
TagPrefix: "urlprefix-",
Register: true,
ServiceAddr: ":9998",
ServiceName: "fabio",
ServiceStatus: []string{"passing"},
CheckInterval: time.Second,
CheckTimeout: 3 * time.Second,
},
},
Listen: []Listen{
{
Addr: ":9999",
},
},
Runtime: Runtime{
GOGC: 800,
GOMAXPROCS: runtime.NumCPU(),
},
UI: UI{
Addr: ":9998",
Color: "light-green",
},
Metrics: []Metrics{
{
Target: "",
Prefix: "default",
Addr: "",
Interval: 30 * time.Second,
},
},
}