Fixes for PT-66

This commit is contained in:
Carlos Salguero
2017-02-09 20:51:39 -03:00
parent 5c16c42ae0
commit 68700a844c
8 changed files with 388 additions and 279 deletions

View File

@@ -1,10 +1,14 @@
package templates
const HostInfo = `# This host
{{ if .ProcPath -}}
# Mongo Executable #######################################################################################
Path to executable | {{.ProcPath}}
# Report On {{.ThisHostID}} ########################################
User | {{.ProcUserName}}
Path to executable | {{.ProcPath }}
{{ end -}}
# Report On {{.Hostname}} ########################################
{{- if .ProcUserName }}
User | {{.ProcUserName }}
{{- end }}
PID Owner | {{.ProcessName}}
Hostname | {{.Hostname}}
Version | {{.Version}}

View File

@@ -2,10 +2,10 @@ package templates
const Replicas = `
# Instances ##############################################################################################
PID Host Type ReplSet Engine
PID Host Type ReplSet Engine
{{- if . -}}
{{- range . }}
{{printf "% 3d" .ID}} {{printf "%-30s" .Name}} {{printf "%-30s" .StateStr}} {{ if .Set }}{{printf "%-10s" .Set }}{{else}}- {{end}} {{printf "%20s" .StorageEngine.Name -}}
{{printf "% 6d" .ID}} {{printf "%-30s" .Name}} {{printf "%-25s" .StateStr}} {{ if .Set }}{{printf "%-10s" .Set }}{{else}}- {{end}} {{printf "%20s" .StorageEngine.Name -}}
{{end}}
{{else}}
no replica sets found