[GLOBAL] Migrate to helm v3
[oom.git] / kubernetes / common / cassandra / templates / statefulset.yaml
index 3553cd4..840e95b 100644 (file)
@@ -28,6 +28,8 @@ spec:
     metadata: {{- include "common.templateMetadata" . | nindent 6 }}
     spec:
       hostNetwork: {{ .Values.hostNetwork }}
+      imagePullSecrets:
+      - name: "{{ include "common.namespace" . }}-docker-registry-key"
       containers:
       - name: {{ include "common.name" . }}
         image: {{ include "repositoryGenerator.dockerHubRepository" . }}/{{ .Values.image }}
@@ -111,14 +113,6 @@ spec:
             value: {{ default "GossipingPropertyFileSnitch" .Values.config.endpoint_snitch | quote }}
           - name: CASSANDRA_AUTHENTICATOR
             value: {{ default "PasswordAuthenticator" .Values.config.authenticator | quote }}
-          {{- if include "common.onServiceMesh" . }}
-          - name: CASSANDRA_LISTEN_ADDRESS
-            value: "127.0.0.1"
-          - name: CASSANDRA_BROADCAST_ADDRESS
-            valueFrom:
-              fieldRef:
-                fieldPath: status.podIP
-          {{- end }}
           - name: POD_IP
             valueFrom:
               fieldRef:
@@ -138,6 +132,7 @@ spec:
       {{- if .Values.affinity }}
       affinity: {{ toYaml .Values.affinity | nindent 8 }}
       {{- end }}
+      serviceAccountName: {{ include "common.fullname" (dict "suffix" "nothing" "dot" . )}}
       volumes:
       - name: localtime
         hostPath: