aboutsummaryrefslogtreecommitdiffstats
path: root/kubernetes/common
diff options
context:
space:
mode:
authorLukasz Rajewski <lukasz.rajewski@t-mobile.pl>2024-01-11 15:44:51 +0000
committerGerrit Code Review <gerrit@onap.org>2024-01-11 15:44:51 +0000
commita4f1fa19963726fd617a9789358fbb3e42a08eb3 (patch)
tree623ac0588993b1e90e31f09d3b45946cefa13068 /kubernetes/common
parent40cbf9be39f507e69e4a0b31b8f6ee5347a3c1a9 (diff)
parent2c1ba293ccef7dcaf09c46f5b0a8a36245238389 (diff)
Merge "[MARIADB][SO] Connect MariaDB Galera via master node"
Diffstat (limited to 'kubernetes/common')
-rw-r--r--kubernetes/common/common/templates/_mariadb.tpl6
-rw-r--r--kubernetes/common/network-name-gen/values.yaml2
2 files changed, 5 insertions, 3 deletions
diff --git a/kubernetes/common/common/templates/_mariadb.tpl b/kubernetes/common/common/templates/_mariadb.tpl
index 7492f71f0a..a2d4117e5c 100644
--- a/kubernetes/common/common/templates/_mariadb.tpl
+++ b/kubernetes/common/common/templates/_mariadb.tpl
@@ -74,14 +74,14 @@
*/}}
{{- define "common.mariadbService" -}}
{{- if .Values.global.mariadbGalera.localCluster -}}
- {{- if .Values.global.mariadbGalera.useOperator }}
+ {{- if and .Values.global.mariadbGalera.useOperator (index .Values "mariadb-galera" "mariadbOperator" "galera" "enabled") }}
{{- printf "%s-primary" (index .Values "mariadb-galera" "nameOverride") -}}
{{- else }}
{{- index .Values "mariadb-galera" "nameOverride" -}}
{{- end }}
{{- else -}}
- {{- if .Values.global.mariadbGalera.useOperator }}
- {{- printf "%s-primary" (.Values.global.mariadbGalera.service) -}}
+ {{- if and .Values.global.mariadbGalera.useOperator }}
+ {{- printf "%s-primary" (.Values.global.mariadbGalera.service) }}
{{- else }}
{{- .Values.global.mariadbGalera.service -}}
{{- end }}
diff --git a/kubernetes/common/network-name-gen/values.yaml b/kubernetes/common/network-name-gen/values.yaml
index 2ab9b93330..e028e39545 100644
--- a/kubernetes/common/network-name-gen/values.yaml
+++ b/kubernetes/common/network-name-gen/values.yaml
@@ -25,6 +25,8 @@ global:
pullPolicy: IfNotPresent
mariadbGalera: &mariadbGalera
+ # flag to enable the DB creation via mariadb-operator
+ useOperator: true
#This flag allows SO to instantiate its own mariadb-galera cluster
#When changing it to "true", also set "globalCluster: false"
#as the dependency check will not work otherwise (Chart.yaml)