| {%- from "kubernetes/map.jinja" import master with context %} |
| {%- from "kubernetes/map.jinja" import pool with context %} |
| |
| {%- if pool.get('enabled', False) %} |
| {% set network = pool.get('network', []) %} |
| {%- else %} |
| {%- if master.get('enabled', False) %} |
| {% set network = master.get('network', []) %} |
| {% endif %} |
| {% endif %} |
| |
| {%- if master.get('enabled', False) or pool.get('enabled', False) %} |
| agent: |
| input: |
| procstat: |
| process: |
| {%- if master.get('enabled', False) %} |
| hyperkube-apiserver: |
| pattern: "hyperkube.*apiserver" |
| hyperkube-scheduler: |
| pattern: "hyperkube.*scheduler" |
| hyperkube-controller-manager: |
| pattern: "hyperkube.*controller-manager" |
| {%- endif %} |
| {%- if pool.get('enabled', False) %} |
| hyperkube-kubelet: |
| pattern: "hyperkube.*kubelet" |
| {%- endif %} |
| {%- if network is defined and network.get('engine', None) == 'calico' %} |
| hyperkube-proxy: |
| pattern: "hyperkube.*proxy" |
| calico-docker: |
| pattern: "docker run .*projectcalico/calico/node" |
| calico-felix: |
| exe: calico-felix |
| bird: |
| pattern: "bird .*/etc/calico/.*/bird.cfg" |
| bird6: |
| pattern: "bird6 .*/etc/calico/.*/bird6.cfg" |
| confd: |
| pattern: "confd .*/etc/calico/confd" |
| calico: |
| template: kubernetes/files/calico_telegraf.conf |
| sockets: {{ sockets | default(["/var/run/calico/bird.ctl"]) | yaml }} |
| {%- endif %} |
| {%- endif %} |