yuryn | fcef994 | 2017-10-26 17:10:50 +0300 | [diff] [blame] | 1 | #{{ if not .Values.disableLogLogstash }} |
Itay Hassid | e2da86d | 2017-08-24 12:54:42 +0000 | [diff] [blame] | 2 | apiVersion: extensions/v1beta1 |
| 3 | kind: Deployment |
| 4 | metadata: |
| 5 | labels: |
| 6 | app: logstash |
BorislavG | 8bfc6cf | 2018-02-27 15:04:26 +0000 | [diff] [blame] | 7 | name: log-logstash |
| 8 | namespace: {{ .Values.nsPrefix }} |
Itay Hassid | e2da86d | 2017-08-24 12:54:42 +0000 | [diff] [blame] | 9 | spec: |
vaibhav_16dec | b7d08b2 | 2018-02-16 06:33:55 +0000 | [diff] [blame] | 10 | replicas: {{ .Values.logstashReplicas }} |
Itay Hassid | e2da86d | 2017-08-24 12:54:42 +0000 | [diff] [blame] | 11 | selector: |
| 12 | matchLabels: |
| 13 | app: logstash |
| 14 | template: |
| 15 | metadata: |
| 16 | labels: |
| 17 | app: logstash |
BorislavG | 8bfc6cf | 2018-02-27 15:04:26 +0000 | [diff] [blame] | 18 | name: log-logstash |
Itay Hassid | e2da86d | 2017-08-24 12:54:42 +0000 | [diff] [blame] | 19 | spec: |
kiranya | 7a31821 | 2017-11-22 13:40:04 +0000 | [diff] [blame] | 20 | initContainers: |
| 21 | - command: |
| 22 | - /root/ready.py |
| 23 | args: |
| 24 | - --container-name |
| 25 | - elasticsearch |
| 26 | env: |
| 27 | - name: NAMESPACE |
| 28 | valueFrom: |
| 29 | fieldRef: |
| 30 | apiVersion: v1 |
| 31 | fieldPath: metadata.namespace |
| 32 | image: {{ .Values.image.readiness }} |
| 33 | imagePullPolicy: {{ .Values.pullPolicy }} |
| 34 | name: logstash-readiness |
Itay Hassid | e2da86d | 2017-08-24 12:54:42 +0000 | [diff] [blame] | 35 | containers: |
| 36 | - name: logstash |
| 37 | image: {{ .Values.image.logstash }} |
| 38 | ports: |
mayankg2703 | 229e537 | 2018-01-29 09:33:56 +0000 | [diff] [blame] | 39 | - containerPort: 5044 |
Itay Hassid | e2da86d | 2017-08-24 12:54:42 +0000 | [diff] [blame] | 40 | name: transport |
| 41 | protocol: TCP |
mayankg2703 | 229e537 | 2018-01-29 09:33:56 +0000 | [diff] [blame] | 42 | - containerPort: 9600 |
| 43 | name: http |
| 44 | protocol: TCP |
Itay Hassid | e2da86d | 2017-08-24 12:54:42 +0000 | [diff] [blame] | 45 | readinessProbe: |
| 46 | tcpSocket: |
| 47 | port: 5044 |
| 48 | volumeMounts: |
| 49 | - mountPath: /usr/share/logstash/config/ |
| 50 | name: logstash-conf |
| 51 | - mountPath: /usr/share/logstash/pipeline/ |
| 52 | name: logstash-pipeline |
| 53 | volumes: |
| 54 | - name: logstash-conf |
| 55 | configMap: |
BorislavG | 8bfc6cf | 2018-02-27 15:04:26 +0000 | [diff] [blame] | 56 | name: log-logstash-configmap |
Itay Hassid | e2da86d | 2017-08-24 12:54:42 +0000 | [diff] [blame] | 57 | items: |
| 58 | - key: logstash.yml |
| 59 | path: logstash.yml |
| 60 | - name: logstash-pipeline |
| 61 | configMap: |
BorislavG | 8bfc6cf | 2018-02-27 15:04:26 +0000 | [diff] [blame] | 62 | name: log-logstash-configmap |
Itay Hassid | e2da86d | 2017-08-24 12:54:42 +0000 | [diff] [blame] | 63 | items: |
| 64 | - key: onap-pipeline.conf |
| 65 | path: onap-pipeline.conf |
| 66 | |
| 67 | --- |
| 68 | apiVersion: v1 |
| 69 | kind: ConfigMap |
| 70 | metadata: |
BorislavG | 8bfc6cf | 2018-02-27 15:04:26 +0000 | [diff] [blame] | 71 | name: log-logstash-configmap |
| 72 | namespace: {{ .Values.nsPrefix }} |
Itay Hassid | e2da86d | 2017-08-24 12:54:42 +0000 | [diff] [blame] | 73 | data: |
BorislavG | 8bfc6cf | 2018-02-27 15:04:26 +0000 | [diff] [blame] | 74 | {{ tpl (.Files.Glob "resources/logstash/conf/logstash.yml").AsConfig . | indent 2 }} |
| 75 | {{ tpl (.Files.Glob "resources/logstash/pipeline/onap-pipeline.conf").AsConfig . | indent 2 }} |
Kerenj | 353ce1d | 2017-11-12 11:08:28 +0200 | [diff] [blame] | 76 | #{{ end }} |