59e69dbfdce7cc6aed05d5782949e5077292d0fa
[oom.git] / kubernetes / sdc / templates / sdc-es.yaml
1 apiVersion: extensions/v1beta1
2 kind: Deployment
3 metadata:
4   labels:
5     app: sdc-es
6   name: sdc-es
7   namespace: "{{ .Values.nsPrefix }}-sdc"
8 spec:
9   selector:
10     matchLabels:
11       app: sdc-es
12   template:
13     metadata:
14       labels:
15         app: sdc-es
16       name: sdc-es
17     spec:
18       containers:
19       - image: {{ .Values.image.sdcElasticsearch }}
20         imagePullPolicy: {{ .Values.pullPolicy }}
21         name: sdc-es
22         env:
23         - name: ENVNAME
24           value: "AUTO"
25         - name: HOST_IP
26           valueFrom:
27             fieldRef:
28               fieldPath: status.podIP
29         - name: ES_HEAP_SIZE
30           value: "1024M"
31         volumeMounts:
32         - mountPath: /usr/share/elasticsearch/data/
33           name: sdc-sdc-es-es
34         - mountPath: /root/chef-solo/environments/
35           name: sdc-environments
36         - mountPath: /etc/localtime
37           name: sdc-localtime
38         - mountPath: /var/lib/jetty/logs
39           name: sdc-logs
40         ports:
41         - containerPort: 9200
42         - containerPort: 9300
43         readinessProbe:
44           tcpSocket:
45             port: 9200
46           initialDelaySeconds: 5
47           periodSeconds: 10
48       volumes:
49         - name: sdc-sdc-es-es
50           hostPath:
51             path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/sdc-es/ES
52         - name: sdc-environments
53           hostPath:
54             path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/environments
55         - name: sdc-localtime
56           hostPath:
57             path:  /etc/localtime
58         - name:  sdc-logs
59           hostPath:
60             path:  /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/logs
61       imagePullSecrets:
62       - name: "{{ .Values.nsPrefix }}-docker-registry-key"