yuryn | 5d0587b | 2017-10-26 17:10:50 +0300 | [diff] [blame^] | 1 | #{{ if not .Values.disableAaiAaiResources }} |
Mandeep Khinda | fc06843 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 2 | apiVersion: extensions/v1beta1 |
| 3 | kind: Deployment |
| 4 | metadata: |
| 5 | name: aai-resources |
| 6 | namespace: "{{ .Values.nsPrefix }}-aai" |
| 7 | spec: |
| 8 | selector: |
| 9 | matchLabels: |
| 10 | app: aai-resources |
| 11 | template: |
| 12 | metadata: |
| 13 | labels: |
| 14 | app: aai-resources |
| 15 | name: aai-resources |
Mandeep Khinda | c432f86 | 2017-09-01 02:15:17 +0000 | [diff] [blame] | 16 | annotations: |
| 17 | pod.beta.kubernetes.io/init-containers: '[ |
| 18 | { |
| 19 | "args": [ |
| 20 | "--container-name", |
| 21 | "hbase" |
| 22 | ], |
| 23 | "command": [ |
| 24 | "/root/ready.py" |
| 25 | ], |
| 26 | "env": [ |
| 27 | { |
| 28 | "name": "NAMESPACE", |
| 29 | "valueFrom": { |
| 30 | "fieldRef": { |
| 31 | "apiVersion": "v1", |
| 32 | "fieldPath": "metadata.namespace" |
| 33 | } |
| 34 | } |
| 35 | } |
| 36 | ], |
yuryn | 4c6a50e | 2017-09-04 16:42:08 +0300 | [diff] [blame] | 37 | "image": "{{ .Values.image.readiness }}", |
| 38 | "imagePullPolicy": "{{ .Values.pullPolicy }}", |
Mandeep Khinda | c432f86 | 2017-09-01 02:15:17 +0000 | [diff] [blame] | 39 | "name": "aai-resources-readiness" |
| 40 | } |
Mike Elliott | 47e76d0 | 2017-09-22 11:31:54 -0400 | [diff] [blame] | 41 | ]' |
Mandeep Khinda | fc06843 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 42 | spec: |
| 43 | containers: |
| 44 | - name: aai-resources |
| 45 | image: "{{ .Values.image.aaiResourcesImage }}:{{ .Values.image.aaiResourcesVersion}}" |
| 46 | imagePullPolicy: {{ .Values.pullPolicy }} |
| 47 | env: |
| 48 | - name: CHEF_BRANCH |
| 49 | value: master |
| 50 | - name: AAI_CHEF_ENV |
| 51 | value: simpledemo |
| 52 | - name: AAI_CORE_VERSION |
| 53 | value: 1.1.0-SNAPSHOT |
| 54 | - name: AAI_CHEF_LOC |
| 55 | value: /var/chef/aai-data/environments |
| 56 | - name: CHEF_GIT_URL |
| 57 | value: http://gerrit.onap.org/r/aai |
Venkata Harish K Kajur | 3078f1e | 2017-10-04 05:06:35 +0000 | [diff] [blame] | 58 | - name: HBASE_STARTUP_ARTIFICIAL_DELAY |
| 59 | value: "60" |
Mandeep Khinda | fc06843 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 60 | volumeMounts: |
yuryn | c400bf5 | 2017-09-13 19:21:03 +0300 | [diff] [blame] | 61 | - mountPath: /etc/localtime |
| 62 | name: localtime |
| 63 | readOnly: true |
Mandeep Khinda | fc06843 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 64 | - mountPath: /var/chef/aai-data/ |
| 65 | name: aai-data |
BorislavG | c4bafe1 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 66 | - mountPath: /var/log/onap |
| 67 | name: aai-resources-logs |
| 68 | - mountPath: /opt/app/aai-resources/bundleconfig/etc/logback.xml |
| 69 | name: aai-resources-log-conf |
| 70 | subPath: logback.xml |
Mandeep Khinda | fc06843 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 71 | ports: |
| 72 | - containerPort: 8447 |
| 73 | readinessProbe: |
| 74 | tcpSocket: |
| 75 | port: 8447 |
| 76 | initialDelaySeconds: 5 |
| 77 | periodSeconds: 10 |
BorislavG | c4bafe1 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 78 | - name: filebeat-onap-aai-resources |
| 79 | image: {{ .Values.image.filebeat }} |
| 80 | imagePullPolicy: {{ .Values.pullPolicy }} |
| 81 | volumeMounts: |
| 82 | - mountPath: /usr/share/filebeat/filebeat.yml |
| 83 | name: filebeat-conf |
| 84 | - mountPath: /var/log/onap |
| 85 | name: aai-resources-logs |
| 86 | - mountPath: /usr/share/filebeat/data |
| 87 | name: aai-resources-filebeat |
Mandeep Khinda | fc06843 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 88 | volumes: |
yuryn | c400bf5 | 2017-09-13 19:21:03 +0300 | [diff] [blame] | 89 | - name: localtime |
| 90 | hostPath: |
| 91 | path: /etc/localtime |
Mandeep Khinda | fc06843 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 92 | - name: aai-data |
| 93 | hostPath: |
| 94 | path: "/dockerdata-nfs/{{ .Values.nsPrefix }}/aai/aai-data/" |
BorislavG | c4bafe1 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 95 | - name: filebeat-conf |
| 96 | hostPath: |
| 97 | path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/filebeat/log4j/filebeat.yml |
| 98 | - name: aai-resources-logs |
| 99 | emptyDir: {} |
| 100 | - name: aai-resources-filebeat |
| 101 | emptyDir: {} |
| 102 | - name: aai-resources-log-conf |
| 103 | configMap: |
| 104 | name: aai-resources-configmap |
Mandeep Khinda | fc06843 | 2017-08-30 14:24:02 +0000 | [diff] [blame] | 105 | restartPolicy: Always |
| 106 | imagePullSecrets: |
| 107 | - name: "{{ .Values.nsPrefix }}-docker-registry-key" |
BorislavG | c4bafe1 | 2017-10-03 15:40:55 +0300 | [diff] [blame] | 108 | --- |
| 109 | apiVersion: v1 |
| 110 | kind: ConfigMap |
| 111 | metadata: |
| 112 | name: aai-resources-configmap |
| 113 | namespace: {{ .Values.nsPrefix }}-aai |
| 114 | data: |
| 115 | {{ (.Files.Glob "resources/resources/conf/logback.xml").AsConfig | indent 2 }} |
yuryn | 5d0587b | 2017-10-26 17:10:50 +0300 | [diff] [blame^] | 116 | #{{ end }} |