Multi-site High-availability Manual Failover (PoC)

Change-Id: I9f1417a77b0e3cae23f55b1bfc1d419730d8f9cd
Signed-off-by: Neha Jain <neha.jain3@amdocs.com>
Issue-ID: SDNC-214
diff --git a/kubernetes/common/mysql/templates/service.yaml b/kubernetes/common/mysql/templates/service.yaml
index ed4f72a..dc63e31 100644
--- a/kubernetes/common/mysql/templates/service.yaml
+++ b/kubernetes/common/mysql/templates/service.yaml
@@ -115,15 +115,15 @@
     statefulset.kubernetes.io/pod-name: {{ include "common.fullname" . }}-0
 spec:
   ports:
-  - name: {{ .Values.service.internalPort }}
+  - name: {{ .Values.service.portName | default .Values.service.name }}-1
     port: {{ .Values.service.internalPort }}
     targetPort: {{ .Values.service.internalPort }}
-    nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.externalPort1 }}
-  - name: {{ .Values.xtrabackup.internalPort }}
+    nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodeport1 }}
+  - name: {{ .Values.service.portName | default .Values.service.name }}-2
     port: {{ .Values.xtrabackup.internalPort }}
     targetPort: {{ .Values.xtrabackup.internalPort }}
-    nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.externalPort2 }}
-  type: NodePort
+    nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodeport2 }}
+  type:  {{ .Values.service.type }}
   selector:
     statefulset.kubernetes.io/pod-name: {{ include "common.fullname" . }}-0
     release: {{ .Release.Name }}