update k8s var condition
This commit is contained in:
@@ -83,18 +83,18 @@ command[check_systemd_{{ service }}]=/usr/lib/nagios/plugins/check_systemd_servi
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
{% if nrpe_kubernetes is defined or nrpe_kubernetes_manager is defined %}
|
||||
{% if nrpe_kubernetes is defined or nrpe_kubernetes_controlplane is defined %}
|
||||
# kubernetes
|
||||
## nodes
|
||||
command[check_systemd_kubelet]=/usr/lib/nagios/plugins/check_systemd_service kubelet
|
||||
command[check_systemd_etcd]=/usr/lib/nagios/plugins/check_systemd_service etcd
|
||||
command[check_systemd_containerd]=/usr/lib/nagios/plugins/check_systemd_service containerd
|
||||
{% if nrpe_kubernetes_manager is defined %}
|
||||
{% if nrpe_kubernetes_controlplane is defined %}
|
||||
## manager / control plane
|
||||
command[check_k8s_health]=/usr/lib/nagios/plugins/check_http -I {{ ansible_default_ipv4.address }} -p 6443 -S -u /healthz --continue-after-certificate -r ok -w 1 -c 2
|
||||
command[check_cilium_health]=/usr/bin/sudo /usr/lib/nagios/plugins/check_cilium_health
|
||||
command[check_coredns_health]=/usr/bin/sudo /usr/lib/nagios/plugins/check_coredns_health
|
||||
command[check_etcd_health]=/usr/bin/sudo /usr/lib/nagios/plugins/check_etcd_health --endpoints "https://{{ ansible_default_ipv4.address }}:2379" --cacert /etc/ssl/etcd/ssl/ca.pem --cert /etc/ssl/etcd/ssl/node-{{ nrpe_kubernetes_manager_nodename }}.pem --key /etc/ssl/etcd/ssl/node-{{ nrpe_kubernetes_manager_nodename }}-key.pem
|
||||
command[check_etcd_health]=/usr/bin/sudo /usr/lib/nagios/plugins/check_etcd_health --endpoints "https://{{ ansible_default_ipv4.address }}:2379" --cacert /etc/ssl/etcd/ssl/ca.pem --cert /etc/ssl/etcd/ssl/node-{{ nrpe_kubernetes_controlplane_nodename }}.pem --key /etc/ssl/etcd/ssl/node-{{ nrpe_kubernetes_controlplane_nodename }}-key.pem
|
||||
command[check_k8s_apiserver_access]=/usr/bin/sudo /usr/lib/nagios/plugins/check_k8s_apiserver_access
|
||||
command[check_k8s_deployments]=/usr/bin/sudo /usr/lib/nagios/plugins/check_k8s_deployments
|
||||
command[check_k8s_jobs_cronjobs]=/usr/bin/sudo /usr/lib/nagios/plugins/check_k8s_jobs_cronjobs
|
||||
|
||||
Reference in New Issue
Block a user