[HOLMES] Use direct name for consul
[oom.git] / kubernetes / holmes / components / holmes-engine-mgmt / templates / deployment.yaml
index fae06da..b625f6d 100644 (file)
@@ -30,6 +30,9 @@ spec:
       - name: init-consul
         image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.consulLoaderImage }}
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        env:
+        - name: CONSUL_HOST
+          value: {{ .Values.consulHost | default "consul-server-ui" }}.{{ include "common.namespace" . }}
         args:
         - --key
         - holmes-engine-mgmt|/hemconfig/cfy.json
@@ -115,6 +118,7 @@ spec:
           value: {{ .Values.config.pgConfig.dbHost }}
         - name: DB_PORT
           value: "{{ .Values.config.pgConfig.dbPort }}"
+      serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
       volumes: {{ include "common.certInitializer.volumes" . | nindent 6 }}
       - name: {{ include "common.fullname" . }}-config
         configMap: