summaryrefslogtreecommitdiffstats
path: root/kubernetes/aai/templates/elasticsearch-deployment.yaml
diff options
context:
space:
mode:
authormayankg2703 <mayank.gupta@amdocs.com>2018-02-05 17:18:18 +0000
committermayankg2703 <mayank.gupta@amdocs.com>2018-02-05 17:19:00 +0000
commit4e6c93342b2383c08c07df1afeef09aa3cee7336 (patch)
tree68bdb2776466d7ee4e283c3580ddab5d818ea703 /kubernetes/aai/templates/elasticsearch-deployment.yaml
parent6ef600ce9d8ab6dd7af3b64363a4d3212ca53036 (diff)
config seg aai elasticsearch
Change-Id: I1d734fee3e487ba7d2e346576e38aba84928928f Issue-ID: OOM-660 Signed-off-by: mayankg2703 <mayank.gupta@amdocs.com>
Diffstat (limited to 'kubernetes/aai/templates/elasticsearch-deployment.yaml')
-rw-r--r--kubernetes/aai/templates/elasticsearch-deployment.yaml31
1 files changed, 27 insertions, 4 deletions
diff --git a/kubernetes/aai/templates/elasticsearch-deployment.yaml b/kubernetes/aai/templates/elasticsearch-deployment.yaml
index 680f942c52..baa1cb8523 100644
--- a/kubernetes/aai/templates/elasticsearch-deployment.yaml
+++ b/kubernetes/aai/templates/elasticsearch-deployment.yaml
@@ -14,6 +14,28 @@ spec:
app: elasticsearch
name: elasticsearch
spec:
+ initContainers:
+ - command:
+ - /bin/sh
+ - -c
+ - |
+ mkdir -p /logroot/elasticsearch/es-data
+ chmod -R 777 /logroot/elasticsearch/es-data
+ chown -R root:root /logroot
+ env:
+ - name: NAMESPACE
+ valueFrom:
+ fieldRef:
+ apiVersion: v1
+ fieldPath: metadata.namespace
+ securityContext:
+ privileged: true
+ image: {{ .Values.image.es_bb }}
+ imagePullPolicy: {{ .Values.pullPolicy }}
+ name: init-sysctl
+ volumeMounts:
+ - name: elasticsearch-data
+ mountPath: /logroot/
hostname: elasticsearch
containers:
- name: elasticsearch
@@ -31,6 +53,7 @@ spec:
mountPath: /etc/localtime
readOnly: true
- name: elasticsearch-config
+ subPath: elasticsearch.yml
mountPath: /usr/share/elasticsearch/config/elasticsearch.yml
- name: elasticsearch-data
mountPath: /usr/share/elasticsearch/data
@@ -39,11 +62,11 @@ spec:
hostPath:
path: /etc/localtime
- name: elasticsearch-config
- hostPath:
- path: "/dockerdata-nfs/{{ .Values.nsPrefix }}/aai/elasticsearch/config/elasticsearch.yml"
+ configMap:
+ name: aai-elasticsearch-configmap
- name: elasticsearch-data
hostPath:
- path: "/dockerdata-nfs/{{ .Values.nsPrefix }}/aai/elasticsearch/es-data"
+ path: "/dockerdata-nfs/{{ .Values.nsPrefix }}/aai/"
imagePullSecrets:
- name: "{{ .Values.nsPrefix }}-docker-registry-key"
-#{{ end }} \ No newline at end of file
+#{{ end }}