Fix Not all namespace/helm installs are deleted
[oom.git] / kubernetes / message-router / templates / message-router-dmaap.yaml
1 #{{ if not .Values.disableMessageRouterDmaap }}
2 apiVersion: extensions/v1beta1
3 kind: Deployment
4 metadata:
5   name: dmaap
6   namespace: "{{ .Values.nsPrefix }}-message-router"
7 spec:
8   selector:
9     matchLabels:
10       app: dmaap
11   template:
12     metadata:
13       labels:
14         app: dmaap
15       name: dmaap
16       annotations:
17         pod.beta.kubernetes.io/init-containers: '[
18           {
19               "args": [
20                   "--container-name",
21                   "global-kafka",
22                   "--container-name",
23                   "zookeeper"
24               ],
25               "command": [
26                   "/root/ready.py"
27               ],
28               "env": [
29                   {
30                       "name": "NAMESPACE",
31                       "valueFrom": {
32                           "fieldRef": {
33                               "apiVersion": "v1",
34                               "fieldPath": "metadata.namespace"
35                           }
36                       }
37                   }
38               ],
39               "image": "{{ .Values.image.readiness }}",
40               "imagePullPolicy": "{{ .Values.pullPolicy }}",
41               "name": "dmaap-readiness"
42           }
43           ]'
44     spec:
45       containers:
46       - image: {{ .Values.image.dmaap }}
47         imagePullPolicy: {{ .Values.pullPolicy }}
48         name: dmaap
49         ports:
50         - containerPort: 3904
51         - containerPort: 3905
52         readinessProbe:
53           tcpSocket:
54             port: 3904
55           initialDelaySeconds: 5
56           periodSeconds: 10
57         volumeMounts:
58         - mountPath: /etc/localtime
59           name: localtime
60           readOnly: true
61         - mountPath: /appl/dmaapMR1/bundleconfig/etc/appprops/MsgRtrApi.properties
62           name: appprops
63         - mountPath: /appl/dmaapMR1/etc/cadi.properties
64           name: cadi
65         - mountPath: /appl/dmaapMR1/etc/keyfile
66           name: mykey
67       restartPolicy: Always
68       volumes:
69       - name: localtime
70         hostPath:
71           path: /etc/localtime
72       - name: appprops
73         hostPath:
74           path: /dockerdata-nfs/{{ .Values.nsPrefix }}/message-router/dmaap/MsgRtrApi.properties
75       - name: cadi
76         hostPath:
77           path: /dockerdata-nfs/{{ .Values.nsPrefix }}/message-router/dmaap/cadi.properties
78       - name: mykey
79         hostPath:
80           path: /dockerdata-nfs/{{ .Values.nsPrefix }}/message-router/dmaap/mykey
81       imagePullSecrets:
82       - name: "{{ .Values.nsPrefix }}-docker-registry-key"
83 {{ end }}