add support to expose via NodePort for vault, argoCD and Grafana

This commit is contained in:
2024-04-29 10:36:30 +03:00
parent 6aac54a915
commit d78b71fb1f
6 changed files with 32 additions and 14 deletions

View File

@@ -9,9 +9,11 @@ type Cicd struct {
Autoscaling bool `yaml:"autoscaling"`
} `yaml:"ha"`
Expose struct {
Type string `yaml:"type"`
Domain string `yaml:"domain"`
Tls struct {
Type string `yaml:"type"`
Domain string `yaml:"domain"`
NodePortHttp int `yaml:"node_port_http" env-default:"30005"`
NodePortHttps int `yaml:"node_port_https" env-default:"30006"`
Tls struct {
Enabled bool `yaml:"enabled"`
} `yaml:"tls"`
} `yaml:"expose"`

View File

@@ -136,9 +136,10 @@ type Visualization struct {
Image string `yaml:"image" env-default:"grafana/grafana"`
Tag string `yaml:"tag" env-default:"10.4.1"`
Expose struct {
Type string `yaml:"type" env-default:"ingress"`
Domain string `yaml:"domain" env-default:""`
Tls struct {
Type string `yaml:"type" env-default:"ingress"`
Domain string `yaml:"domain" env-default:""`
NodePortHttp int `yaml:"node_port_http" env-default:"30007"`
Tls struct {
Enabled bool `yaml:"enabled"`
}
} `yaml:"expose"`

View File

@@ -15,7 +15,12 @@
server:
certificateSecret:
enabled: false
{{- if eq .Modules.Cicd.ArgoCd.Expose.Type "NodePort" }}
service:
type: "NodePort"
nodePortHttp: {{ .Modules.Cicd.ArgoCd.Expose.NodePortHttp }}
nodePortHttps: {{ .Modules.Cicd.ArgoCd.Expose.NodePortHttps }}
{{- end }}
{{- if .Modules.Cicd.ArgoCd.Ha.Enabled }}
{{- if .Modules.Cicd.ArgoCd.Ha.Autoscaling }}
autoscaling:

View File

@@ -208,6 +208,10 @@
enabled: {{ and .Modules.Observability.Enabled .Modules.Observability.Visualization.Grafana.Enabled }}
serviceMonitor: {{ .Modules.Observability.Monitoring.Enabled }}
domain: &grafanaDomain {{ .Modules.Observability.Visualization.Grafana.Expose.Domain }}
{{- if eq .Modules.Observability.Visualization.Grafana.Expose.Type "NodePort" }}
serviceNodePort: {{ .Modules.Observability.Visualization.Grafana.Expose.NodePortHttp }}
{{- end }}
image:
repository: {{ .Modules.Observability.Visualization.Grafana.Image }}
tag: {{ .Modules.Observability.Visualization.Grafana.Tag }}
@@ -281,6 +285,8 @@
ingress:
{{- if eq .Modules.Observability.Visualization.Grafana.Expose.Type "ingress" }}
enabled: true
{{- else }}
enabled: false
{{- end }}
accountEmail: {{ .Modules.Additional.CertManager.AccountEmail }}
class: {{ .Modules.Additional.Ingress.Type }}