blob: f38dbd71d9d1d57a588fc76e13c658eb57ea85db [file] [log] [blame]
yurynfcef9942017-10-26 17:10:50 +03001#{{ if not .Values.disableSdcSdcBe }}
Mandeep Khindad6ea9872017-06-24 11:49:37 -04002apiVersion: extensions/v1beta1
3kind: Deployment
4metadata:
5 labels:
6 app: sdc-be
7 name: sdc-be
Mandeep Khinda0e8f8892017-08-25 03:31:17 +00008 namespace: "{{ .Values.nsPrefix }}-sdc"
Mandeep Khindad6ea9872017-06-24 11:49:37 -04009spec:
10 selector:
11 matchLabels:
12 app: sdc-be
13 template:
14 metadata:
15 labels:
16 app: sdc-be
17 name: sdc-be
18 annotations:
19 pod.beta.kubernetes.io/init-containers: '[
20 {
21 "args": [
22 "--container-name",
23 "sdc-es",
24 "--container-name",
25 "sdc-cs",
26 "--container-name",
27 "sdc-kb"
28 ],
29 "command": [
30 "/root/ready.py"
31 ],
32 "env": [
33 {
34 "name": "NAMESPACE",
35 "valueFrom": {
36 "fieldRef": {
37 "apiVersion": "v1",
38 "fieldPath": "metadata.namespace"
39 }
40 }
41 }
42 ],
kerenj80102842017-08-24 13:54:21 +000043 "image": "{{ .Values.image.readiness }}",
44 "imagePullPolicy": "{{ .Values.pullPolicy }}",
Mandeep Khindad6ea9872017-06-24 11:49:37 -040045 "name": "sdc-be-readiness"
46 },
47 {
48 "args": [
49 "--container-name",
50 "dmaap"
51 ],
52 "command": [
53 "/root/ready.py"
54 ],
55 "env": [
56 {
57 "name": "NAMESPACE",
Mandeep Khinda0e8f8892017-08-25 03:31:17 +000058 "value": "{{ .Values.nsPrefix }}-message-router"
Mandeep Khindad6ea9872017-06-24 11:49:37 -040059 }
60 ],
kerenj80102842017-08-24 13:54:21 +000061 "image": "{{ .Values.image.readiness }}",
62 "imagePullPolicy": "{{ .Values.pullPolicy }}",
Mandeep Khindad6ea9872017-06-24 11:49:37 -040063 "name": "sdc-dmaap-readiness"
64 }
65 ]'
66 spec:
67 containers:
68 - env:
69 - name: ENVNAME
70 value: AUTO
71 - name: HOST_IP
72 valueFrom:
73 fieldRef:
74 fieldPath: status.podIP
kerenj80102842017-08-24 13:54:21 +000075 image: {{ .Values.image.sdcBackend }}
76 imagePullPolicy: {{ .Values.pullPolicy }}
Mandeep Khindad6ea9872017-06-24 11:49:37 -040077 name: sdc-be
78 volumeMounts:
79 - mountPath: /usr/share/elasticsearch/data/
80 name: sdc-sdc-es-es
81 - mountPath: /root/chef-solo/environments/
82 name: sdc-environments
Mandeep Khindad6ea9872017-06-24 11:49:37 -040083 - mountPath: /etc/localtime
84 name: sdc-localtime
yuryn8b3bc5a2017-09-13 19:21:03 +030085 readOnly: true
Mandeep Khindad6ea9872017-06-24 11:49:37 -040086 - mountPath: /var/lib/jetty/logs
87 name: sdc-logs
yurynd0707be2017-09-27 14:54:18 +030088 - mountPath: /var/log/onap
89 name: sdc-logs-2
Mandeep Khinda11982f72017-10-13 17:54:20 +000090 - mountPath: /tmp/logback.xml
yurynd0707be2017-09-27 14:54:18 +030091 name: sdc-logback
Mandeep Khinda11982f72017-10-13 17:54:20 +000092 lifecycle:
93 postStart:
94 exec:
95 command: ["/bin/sh", "-c", "export LOG=wait_logback.log; touch $LOG; export SRC=/tmp/logback.xml; export DST=/var/lib/jetty/config/catalog-be/; while [ ! -e $DST ]; do echo 'Waiting for $DST...' >> $LOG; sleep 5; done; sleep 2; /bin/cp -f $SRC $DST; echo 'Done' >> $LOG"]
Mandeep Khindad6ea9872017-06-24 11:49:37 -040096 ports:
97 - containerPort: 8443
98 - containerPort: 8080
99 readinessProbe:
100 tcpSocket:
101 port: 8443
102 initialDelaySeconds: 5
103 periodSeconds: 10
yurynd0707be2017-09-27 14:54:18 +0300104 - image: {{ .Values.image.filebeat }}
105 imagePullPolicy: {{ .Values.pullPolicy }}
106 name: filebeat-onap
107 volumeMounts:
108 - mountPath: /usr/share/filebeat/filebeat.yml
109 name: filebeat-conf
110 - mountPath: /var/log/onap
111 name: sdc-logs-2
112 - mountPath: /usr/share/filebeat/data
113 name: sdc-data-filebeat
Mandeep Khindad6ea9872017-06-24 11:49:37 -0400114 volumes:
yurynd0707be2017-09-27 14:54:18 +0300115 - name: filebeat-conf
116 hostPath:
117 path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/filebeat/logback/filebeat.yml
118 - name: sdc-logs-2
119 emptyDir: {}
120 - name: sdc-data-filebeat
121 emptyDir: {}
122 - name: sdc-logback
123 hostPath:
124 path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/sdc/be/logback.xml
Mandeep Khindad6ea9872017-06-24 11:49:37 -0400125 - name: sdc-sdc-es-es
126 hostPath:
Mandeep Khinda0e8f8892017-08-25 03:31:17 +0000127 path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/sdc-es/ES
Mandeep Khindad6ea9872017-06-24 11:49:37 -0400128 - name: sdc-environments
129 hostPath:
Mandeep Khinda0e8f8892017-08-25 03:31:17 +0000130 path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/environments
Mandeep Khindad6ea9872017-06-24 11:49:37 -0400131 - name: sdc-localtime
132 hostPath:
133 path: /etc/localtime
134 - name: sdc-logs
135 hostPath:
Mandeep Khinda0e8f8892017-08-25 03:31:17 +0000136 path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/logs
Borislav Glozman5197e2e2017-07-24 10:45:28 +0300137 imagePullSecrets:
Mandeep Khinda0e8f8892017-08-25 03:31:17 +0000138 - name: "{{ .Values.nsPrefix }}-docker-registry-key"
yurynfcef9942017-10-26 17:10:50 +0300139#{{ end }}