yuryn | fcef994 | 2017-10-26 17:10:50 +0300 | [diff] [blame] | 1 | #{{ if not .Values.disableAaiModelLoaderService }} |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 2 | apiVersion: extensions/v1beta1 |
| 3 | kind: Deployment |
| 4 | metadata: |
| 5 | name: model-loader-service |
Mandeep Khinda | 0e8f889 | 2017-08-25 03:31:17 +0000 | [diff] [blame] | 6 | namespace: "{{ .Values.nsPrefix }}-aai" |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 7 | spec: |
| 8 | selector: |
| 9 | matchLabels: |
| 10 | app: model-loader-service |
| 11 | template: |
| 12 | metadata: |
| 13 | labels: |
| 14 | app: model-loader-service |
| 15 | name: model-loader-service |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 16 | spec: |
| 17 | containers: |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 18 | - name: model-loader-service |
| 19 | image: "{{ .Values.image.modelLoaderImage }}:{{ .Values.image.modelLoaderVersion }}" |
| 20 | imagePullPolicy: {{ .Values.pullPolicy }} |
| 21 | env: |
Mandeep Khinda | 4b88197 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 22 | - name: CONFIG_HOME |
| 23 | value: /opt/app/model-loader/config/ |
| 24 | volumeMounts: |
yuryn | 8b3bc5a | 2017-09-13 19:21:03 +0300 | [diff] [blame] | 25 | - mountPath: /etc/localtime |
| 26 | name: localtime |
| 27 | readOnly: true |
Mandeep Khinda | 4b88197 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 28 | - mountPath: /opt/app/model-loader/config/ |
| 29 | name: aai-model-loader-config |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 30 | - mountPath: /var/log/onap |
Mandeep Khinda | 4b88197 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 31 | name: aai-model-loader-logs |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 32 | - mountPath: /opt/app/model-loader/bundleconfig/etc/logback.xml |
| 33 | name: aai-model-loader-log-conf |
| 34 | subPath: logback.xml |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 35 | ports: |
| 36 | - containerPort: 8080 |
| 37 | - containerPort: 8443 |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 38 | - name: filebeat-onap-aai-model-loader |
| 39 | image: {{ .Values.image.filebeat }} |
| 40 | imagePullPolicy: {{ .Values.pullPolicy }} |
| 41 | volumeMounts: |
| 42 | - mountPath: /usr/share/filebeat/filebeat.yml |
| 43 | name: filebeat-conf |
| 44 | - mountPath: /var/log/onap |
| 45 | name: aai-model-loader-logs |
| 46 | - mountPath: /usr/share/filebeat/data |
| 47 | name: aai-model-loader-filebeat |
Mandeep Khinda | 4b88197 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 48 | volumes: |
yuryn | 8b3bc5a | 2017-09-13 19:21:03 +0300 | [diff] [blame] | 49 | - name: localtime |
| 50 | hostPath: |
| 51 | path: /etc/localtime |
Mandeep Khinda | 4b88197 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 52 | - name: aai-model-loader-config |
| 53 | hostPath: |
| 54 | path: "/dockerdata-nfs/{{ .Values.nsPrefix }}/aai/model-loader/appconfig/" |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 55 | - name: filebeat-conf |
Mandeep Khinda | 4b88197 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 56 | hostPath: |
shanedaniel | af561c1 | 2017-10-19 19:10:33 +0000 | [diff] [blame] | 57 | path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/filebeat/logback/filebeat.yml |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 58 | - name: aai-model-loader-logs |
| 59 | emptyDir: {} |
| 60 | - name: aai-model-loader-filebeat |
| 61 | emptyDir: {} |
| 62 | - name: aai-model-loader-log-conf |
| 63 | configMap: |
| 64 | name: aai-model-loader-configmap |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 65 | restartPolicy: Always |
Borislav Glozman | 5197e2e | 2017-07-24 10:45:28 +0300 | [diff] [blame] | 66 | imagePullSecrets: |
Alexis de Talhouƫt | 91c7710 | 2017-09-26 10:29:32 -0400 | [diff] [blame] | 67 | - name: "{{ .Values.nsPrefix }}-docker-registry-key" |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 68 | --- |
| 69 | apiVersion: v1 |
| 70 | kind: ConfigMap |
| 71 | metadata: |
| 72 | name: aai-model-loader-configmap |
| 73 | namespace: {{ .Values.nsPrefix }}-aai |
| 74 | data: |
| 75 | {{ (.Files.Glob "resources/model-loader/conf/logback.xml").AsConfig | indent 2 }} |
yuryn | fcef994 | 2017-10-26 17:10:50 +0300 | [diff] [blame] | 76 | #{{ end }} |