diff options
author | BorislavG <Borislav.Glozman@amdocs.com> | 2018-02-27 15:04:26 +0000 |
---|---|---|
committer | Alexis de Talhouƫt <alexis.de_talhouet@bell.ca> | 2018-03-01 18:10:31 +0000 |
commit | 8bfc6cf8c3d338c84c48201f7a4f274958e721a9 (patch) | |
tree | 2e0e1a969afc6ae38f0a2f62cc1a36e184cb48e1 /kubernetes/sdnc/templates/db-statefulset.yaml | |
parent | f0a34e22011b4323bbd6a51ad313d6e547808101 (diff) |
Run all components in one namespace
Change-Id: I5fcd4d577c1fda4de27842807c7cf7a5d372756e
Issue-ID: OOM-722
Signed-off-by: BorislavG <Borislav.Glozman@amdocs.com>
Diffstat (limited to 'kubernetes/sdnc/templates/db-statefulset.yaml')
-rw-r--r-- | kubernetes/sdnc/templates/db-statefulset.yaml | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/kubernetes/sdnc/templates/db-statefulset.yaml b/kubernetes/sdnc/templates/db-statefulset.yaml index f2e079d76e..399eb42239 100644 --- a/kubernetes/sdnc/templates/db-statefulset.yaml +++ b/kubernetes/sdnc/templates/db-statefulset.yaml @@ -3,7 +3,7 @@ apiVersion: apps/v1beta1 kind: StatefulSet metadata: name: sdnc-dbhost - namespace: "{{ .Values.nsPrefix }}-sdnc" + namespace: "{{ .Values.nsPrefix }}" spec: serviceName: "dbhost" replicas: {{ .Values.numberOfDbReplicas }} @@ -61,7 +61,7 @@ spec: echo ${BASH_REMATCH} [[ $ordinal -eq 0 ]] && exit 0 # Clone data from previous peer. - ncat --recv-only sdnc-dbhost-$(($ordinal-1)).dbhost.{{ .Values.nsPrefix }}-sdnc 3307 | xbstream -x -C /var/lib/mysql + ncat --recv-only sdnc-dbhost-$(($ordinal-1)).dbhost.{{ .Values.nsPrefix }} 3307 | xbstream -x -C /var/lib/mysql # Prepare the backup. xtrabackup --user=root --password=$MYSQL_ROOT_PASSWORD --prepare --target-dir=/var/lib/mysql ls -l /var/lib/mysql @@ -150,7 +150,7 @@ spec: mv change_master_to.sql.in change_master_to.sql.orig mysql --user=root --password=$MYSQL_ROOT_PASSWORD -h 127.0.0.1 <<EOF $(<change_master_to.sql.orig), - MASTER_HOST="sdnc-dbhost-0.dbhost.{{ .Values.nsPrefix }}-sdnc", + MASTER_HOST="sdnc-dbhost-0.dbhost.{{ .Values.nsPrefix }}", MASTER_USER="root", MASTER_PASSWORD="$MYSQL_ROOT_PASSWORD", MASTER_CONNECT_RETRY=10; @@ -176,10 +176,15 @@ spec: emptyDir: {} - name: config-map configMap: - name: mysql + name: sdnc-mysql - name: localtime hostPath: path: /etc/localtime +#{{ if .Values.disableNfsProvisioner }} + - name: sdnc-data + hostPath: + path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdnc/data +#{{ else }} volumeClaimTemplates: - metadata: name: sdnc-data @@ -191,3 +196,4 @@ spec: requests: storage: 1Gi #{{ end }} +#{{ end }} |