Merge "config-init time optimization"
[oom.git] / kubernetes / sdc / templates / sdc-es.yaml
1 #{{ if not .Values.disableSdcSdcEs }}
2 apiVersion: extensions/v1beta1
3 kind: Deployment
4 metadata:
5   labels:
6     app: sdc-es
7   name: sdc-es
8   namespace: "{{ .Values.nsPrefix }}-sdc"
9 spec:
10   selector:
11     matchLabels:
12       app: sdc-es
13   template:
14     metadata:
15       labels:
16         app: sdc-es
17       name: sdc-es
18     spec:
19       containers:
20       - image: {{ .Values.image.sdcElasticsearch }}
21         imagePullPolicy: {{ .Values.pullPolicy }}
22         name: sdc-es
23         env:
24         - name: ENVNAME
25           value: "AUTO"
26         - name: HOST_IP
27           valueFrom:
28             fieldRef:
29               fieldPath: status.podIP
30         - name: ES_HEAP_SIZE
31           value: "1024M"
32         volumeMounts:
33         - mountPath: /root/chef-solo/environments/
34           name: sdc-environments
35         - mountPath: /etc/localtime
36           name: sdc-localtime
37           readOnly: true
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-environments
50           hostPath:
51             path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/environments
52         - name: sdc-localtime
53           hostPath:
54             path:  /etc/localtime
55         - name:  sdc-logs
56           hostPath:
57             path:  /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/logs
58       imagePullSecrets:
59       - name: "{{ .Values.nsPrefix }}-docker-registry-key"
60 #{{ end }}