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 |
mayankg2703 | 135d891 | 2018-02-06 10:28:00 +0000 | [diff] [blame] | 28 | - mountPath: /opt/app/model-loader/config/model-loader.properties |
| 29 | subPath: model-loader.properties |
| 30 | name: aai-model-loader-prop-config |
| 31 | - mountPath: /opt/app/model-loader/config/auth/ |
| 32 | name: aai-model-loader-auth-config |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 33 | - mountPath: /var/log/onap |
Mandeep Khinda | 4b88197 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 34 | name: aai-model-loader-logs |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 35 | - mountPath: /opt/app/model-loader/bundleconfig/etc/logback.xml |
| 36 | name: aai-model-loader-log-conf |
| 37 | subPath: logback.xml |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 38 | ports: |
| 39 | - containerPort: 8080 |
| 40 | - containerPort: 8443 |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 41 | - name: filebeat-onap-aai-model-loader |
| 42 | image: {{ .Values.image.filebeat }} |
| 43 | imagePullPolicy: {{ .Values.pullPolicy }} |
| 44 | volumeMounts: |
| 45 | - mountPath: /usr/share/filebeat/filebeat.yml |
mayankg2703 | 135d891 | 2018-02-06 10:28:00 +0000 | [diff] [blame] | 46 | subPath: filebeat.yml |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 47 | name: filebeat-conf |
| 48 | - mountPath: /var/log/onap |
| 49 | name: aai-model-loader-logs |
| 50 | - mountPath: /usr/share/filebeat/data |
| 51 | name: aai-model-loader-filebeat |
Mandeep Khinda | 4b88197 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 52 | volumes: |
yuryn | 8b3bc5a | 2017-09-13 19:21:03 +0300 | [diff] [blame] | 53 | - name: localtime |
| 54 | hostPath: |
| 55 | path: /etc/localtime |
mayankg2703 | 135d891 | 2018-02-06 10:28:00 +0000 | [diff] [blame] | 56 | - name: aai-model-loader-prop-config |
| 57 | configMap: |
| 58 | name: model-loader-prop-configmap |
| 59 | - name: aai-model-loader-auth-config |
| 60 | secret: |
| 61 | secretName: model-loader-secret |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 62 | - name: filebeat-conf |
mayankg2703 | 135d891 | 2018-02-06 10:28:00 +0000 | [diff] [blame] | 63 | configMap: |
| 64 | name: aai-filebeat-configmap |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 65 | - name: aai-model-loader-logs |
| 66 | emptyDir: {} |
| 67 | - name: aai-model-loader-filebeat |
| 68 | emptyDir: {} |
| 69 | - name: aai-model-loader-log-conf |
| 70 | configMap: |
| 71 | name: aai-model-loader-configmap |
Mandeep Khinda | d6ea987 | 2017-06-24 11:49:37 -0400 | [diff] [blame] | 72 | restartPolicy: Always |
Borislav Glozman | 5197e2e | 2017-07-24 10:45:28 +0300 | [diff] [blame] | 73 | imagePullSecrets: |
Alexis de Talhouƫt | 91c7710 | 2017-09-26 10:29:32 -0400 | [diff] [blame] | 74 | - name: "{{ .Values.nsPrefix }}-docker-registry-key" |
BorislavG | b2b9918 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 75 | --- |
| 76 | apiVersion: v1 |
| 77 | kind: ConfigMap |
| 78 | metadata: |
| 79 | name: aai-model-loader-configmap |
| 80 | namespace: {{ .Values.nsPrefix }}-aai |
| 81 | data: |
| 82 | {{ (.Files.Glob "resources/model-loader/conf/logback.xml").AsConfig | indent 2 }} |
mayankg2703 | 135d891 | 2018-02-06 10:28:00 +0000 | [diff] [blame] | 83 | #{{ end }} |