DNS upstream servers report

This commit is contained in:
Alvaro Saurin committed 2015-11-19 14:54:23 +01:00
1 parent 7987d09438
commit 7992bf4177
2 files changed
+13 -4

No files matched your search

+7
View File
@@ -25,6 +25,12 @@ var rootTemplate = template.New("root").Funcs(map[string]interface{}{
}
return count
},
"upstreamServers": func(servers []string) string {
if len(servers) == 0 {
return "none"
}
return strings.Join(servers, ", ")
},
"printConnectionCounts": func(conns []mesh.LocalConnectionStatus) string {
counts := make(map[string]int)
for _, conn := range conns {
@@ -108,6 +114,7 @@ var statusTemplate = defTemplate("status", `\
Service: dns
Domain: {{.DNS.Domain}}
Upstream: {{upstreamServers .DNS.Upstream}}
TTL: {{.DNS.TTL}}
Entries: {{countDNSEntries .DNS.Entries}}
{{end}}\