25 lines
523 B
Go
25 lines
523 B
Go
|
package helm
|
||
|
|
||
|
import "strings"
|
||
|
|
||
|
var NOTES = `
|
||
|
Congratulations,
|
||
|
|
||
|
Your application is now deployed. This may take a while to be up and responding.
|
||
|
|
||
|
__list__
|
||
|
`
|
||
|
|
||
|
func GenNotes(ingressess map[string]*Ingress) string {
|
||
|
|
||
|
list := make([]string, 0)
|
||
|
|
||
|
for name, ing := range ingressess {
|
||
|
for _, r := range ing.Spec.Rules {
|
||
|
list = append(list, "{{ if .Values."+name+".ingress.enabled }}- "+name+" is accessible on : http://"+r.Host+"{{- end }}")
|
||
|
}
|
||
|
}
|
||
|
|
||
|
return strings.ReplaceAll(NOTES, "__list__", strings.Join(list, "\n"))
|
||
|
}
|