create K8S cluster by TOSCA
[oom.git] / kubernetes / message-router / templates / message-router-zookeeper.yaml
1 #{{ if not .Values.disableMessageRouterZookeeper }}
2 apiVersion: extensions/v1beta1
3 kind: Deployment
4 metadata:
5   name: zookeeper
6   namespace: "{{ .Values.nsPrefix }}-message-router"
7 spec:
8   selector:
9     matchLabels:
10       app: zookeeper
11   template:
12     metadata:
13       labels:
14         app: zookeeper
15       name: zookeeper
16     spec:
17       containers:
18       - image: {{ .Values.image.zookeeper }}
19         imagePullPolicy: {{ .Values.pullPolicy }}
20         name: zookeeper
21         ports:
22         - containerPort: 2181
23         readinessProbe:
24           tcpSocket:
25             port: 2181
26           initialDelaySeconds: 5
27           periodSeconds: 10
28         volumeMounts:
29         - mountPath: /etc/localtime
30           name: localtime
31           readOnly: true
32         - mountPath: /opt/zookeeper-3.4.9/data
33           name: zookeeper-data
34       restartPolicy: Always
35       volumes:
36       - name: localtime
37         hostPath:
38           path: /etc/localtime
39       - name: zookeeper-data
40         persistentVolumeClaim:
41           claimName: message-router-zookeeper
42       imagePullSecrets:
43       - name: "{{ .Values.nsPrefix }}-docker-registry-key"
44 #{{ end }}