yuryn | fcef994 | 2017-10-26 17:10:50 +0300 | [diff] [blame] | 1 | #{{ if not .Values.disableSdcSdcBe }} |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 2 | apiVersion: extensions/v1beta1 |
| 3 | kind: Deployment |
| 4 | metadata: |
| 5 | labels: |
| 6 | app: sdc-be |
| 7 | name: sdc-be |
Mandeep Khinda | 0e8f889 | 2017-08-25 03:31:17 +0000 | [diff] [blame] | 8 | namespace: "{{ .Values.nsPrefix }}-sdc" |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 9 | spec: |
| 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 | ], |
kerenj | 8010284 | 2017-08-24 13:54:21 +0000 | [diff] [blame] | 43 | "image": "{{ .Values.image.readiness }}", |
| 44 | "imagePullPolicy": "{{ .Values.pullPolicy }}", |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 45 | "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 Khinda | 0e8f889 | 2017-08-25 03:31:17 +0000 | [diff] [blame] | 58 | "value": "{{ .Values.nsPrefix }}-message-router" |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 59 | } |
| 60 | ], |
kerenj | 8010284 | 2017-08-24 13:54:21 +0000 | [diff] [blame] | 61 | "image": "{{ .Values.image.readiness }}", |
| 62 | "imagePullPolicy": "{{ .Values.pullPolicy }}", |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 63 | "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 |
kerenj | 8010284 | 2017-08-24 13:54:21 +0000 | [diff] [blame] | 75 | image: {{ .Values.image.sdcBackend }} |
| 76 | imagePullPolicy: {{ .Values.pullPolicy }} |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 77 | 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 Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 83 | - mountPath: /etc/localtime |
| 84 | name: sdc-localtime |
yuryn | 8b3bc5a | 2017-09-13 19:21:03 +0300 | [diff] [blame] | 85 | readOnly: true |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 86 | - mountPath: /var/lib/jetty/logs |
| 87 | name: sdc-logs |
yuryn | d0707be | 2017-09-27 14:54:18 +0300 | [diff] [blame] | 88 | - mountPath: /var/log/onap |
| 89 | name: sdc-logs-2 |
Mandeep Khinda | 11982f7 | 2017-10-13 17:54:20 +0000 | [diff] [blame] | 90 | - mountPath: /tmp/logback.xml |
yuryn | d0707be | 2017-09-27 14:54:18 +0300 | [diff] [blame] | 91 | name: sdc-logback |
Mandeep Khinda | 11982f7 | 2017-10-13 17:54:20 +0000 | [diff] [blame] | 92 | 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 Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 96 | ports: |
| 97 | - containerPort: 8443 |
| 98 | - containerPort: 8080 |
| 99 | readinessProbe: |
| 100 | tcpSocket: |
| 101 | port: 8443 |
| 102 | initialDelaySeconds: 5 |
| 103 | periodSeconds: 10 |
yuryn | d0707be | 2017-09-27 14:54:18 +0300 | [diff] [blame] | 104 | - 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 Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 114 | volumes: |
yuryn | d0707be | 2017-09-27 14:54:18 +0300 | [diff] [blame] | 115 | - 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 Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 125 | - name: sdc-sdc-es-es |
| 126 | hostPath: |
Mandeep Khinda | 0e8f889 | 2017-08-25 03:31:17 +0000 | [diff] [blame] | 127 | path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/sdc-es/ES |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 128 | - name: sdc-environments |
| 129 | hostPath: |
Mandeep Khinda | 0e8f889 | 2017-08-25 03:31:17 +0000 | [diff] [blame] | 130 | path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/environments |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 131 | - name: sdc-localtime |
| 132 | hostPath: |
| 133 | path: /etc/localtime |
| 134 | - name: sdc-logs |
| 135 | hostPath: |
Mandeep Khinda | 0e8f889 | 2017-08-25 03:31:17 +0000 | [diff] [blame] | 136 | path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/logs |
Borislav Glozman | 5197e2e | 2017-07-24 10:45:28 +0300 | [diff] [blame] | 137 | imagePullSecrets: |
Mandeep Khinda | 0e8f889 | 2017-08-25 03:31:17 +0000 | [diff] [blame] | 138 | - name: "{{ .Values.nsPrefix }}-docker-registry-key" |
yuryn | fcef994 | 2017-10-26 17:10:50 +0300 | [diff] [blame] | 139 | #{{ end }} |