mirror of
https://github.com/Control-D-Inc/ctrld.git
synced 2026-08-10 13:20:33 +02:00
Add listener policy to default generated config
So technical user can figure thing out based on self-documented commands, without referring to actual documentation.
This commit is contained in:
@@ -82,6 +82,16 @@ func InitConfig(v *viper.Viper, name string) {
|
||||
"0": {
|
||||
IP: "",
|
||||
Port: 0,
|
||||
Policy: &ListenerPolicyConfig{
|
||||
Name: "Main Policy",
|
||||
Networks: []Rule{
|
||||
{"network.0": []string{"upstream.0"}},
|
||||
},
|
||||
Rules: []Rule{
|
||||
{"example.com": []string{"upstream.0"}},
|
||||
{"*.ads.com": []string{"upstream.1"}},
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
v.SetDefault("network", map[string]*NetworkConfig{
|
||||
|
||||
Reference in New Issue
Block a user