From 42d8ba2d43ed96ed417a5f681a776c918f22202a Mon Sep 17 00:00:00 2001 From: "mergify[bot]" <37929162+mergify[bot]@users.noreply.github.com> Date: Wed, 17 Aug 2022 09:40:53 -0400 Subject: [PATCH] Add control-plane toleration to Agent K8S manifests. (#864) (#907) * Add toleration to elastic-agent Kubernetes manifests. The toleration with key node-role.kubernetes.io/control-plane is set to replace the deprecated toleration with key node-role.kubernetes.io/master which will be removed by Kubernetes v1.25 * Remove outdated "master" node terminology. (cherry picked from commit 689aee33c923be6183267c0e45596aa8d758e6eb) Co-authored-by: Yash Tewari --- deploy/kubernetes/elastic-agent-managed-kubernetes.yaml | 6 ++++-- .../elastic-agent-managed-daemonset.yaml | 6 ++++-- deploy/kubernetes/elastic-agent-standalone-kubernetes.yaml | 6 ++++-- .../elastic-agent-standalone-daemonset.yaml | 6 ++++-- 4 files changed, 16 insertions(+), 8 deletions(-) diff --git a/deploy/kubernetes/elastic-agent-managed-kubernetes.yaml b/deploy/kubernetes/elastic-agent-managed-kubernetes.yaml index 06992f8b87f..b1e950ec7ff 100644 --- a/deploy/kubernetes/elastic-agent-managed-kubernetes.yaml +++ b/deploy/kubernetes/elastic-agent-managed-kubernetes.yaml @@ -15,9 +15,11 @@ spec: labels: app: elastic-agent spec: - # Tolerations are needed to run Elastic Agent on Kubernetes master nodes. - # Agents running on master nodes collect metrics from the control plane components (scheduler, controller manager) of Kubernetes + # Tolerations are needed to run Elastic Agent on Kubernetes control-plane nodes. + # Agents running on control-plane nodes collect metrics from the control plane components (scheduler, controller manager) of Kubernetes tolerations: + - key: node-role.kubernetes.io/control-plane + effect: NoSchedule - key: node-role.kubernetes.io/master effect: NoSchedule serviceAccountName: elastic-agent diff --git a/deploy/kubernetes/elastic-agent-managed/elastic-agent-managed-daemonset.yaml b/deploy/kubernetes/elastic-agent-managed/elastic-agent-managed-daemonset.yaml index c3c679efa36..fac245ca69a 100644 --- a/deploy/kubernetes/elastic-agent-managed/elastic-agent-managed-daemonset.yaml +++ b/deploy/kubernetes/elastic-agent-managed/elastic-agent-managed-daemonset.yaml @@ -15,9 +15,11 @@ spec: labels: app: elastic-agent spec: - # Tolerations are needed to run Elastic Agent on Kubernetes master nodes. - # Agents running on master nodes collect metrics from the control plane components (scheduler, controller manager) of Kubernetes + # Tolerations are needed to run Elastic Agent on Kubernetes control-plane nodes. + # Agents running on control-plane nodes collect metrics from the control plane components (scheduler, controller manager) of Kubernetes tolerations: + - key: node-role.kubernetes.io/control-plane + effect: NoSchedule - key: node-role.kubernetes.io/master effect: NoSchedule serviceAccountName: elastic-agent diff --git a/deploy/kubernetes/elastic-agent-standalone-kubernetes.yaml b/deploy/kubernetes/elastic-agent-standalone-kubernetes.yaml index 44769d5828d..ce7141dcd6b 100644 --- a/deploy/kubernetes/elastic-agent-standalone-kubernetes.yaml +++ b/deploy/kubernetes/elastic-agent-standalone-kubernetes.yaml @@ -640,9 +640,11 @@ spec: labels: app: elastic-agent-standalone spec: - # Tolerations are needed to run Elastic Agent on Kubernetes master nodes. - # Agents running on master nodes collect metrics from the control plane components (scheduler, controller manager) of Kubernetes + # Tolerations are needed to run Elastic Agent on Kubernetes control-plane nodes. + # Agents running on control-plane nodes collect metrics from the control plane components (scheduler, controller manager) of Kubernetes tolerations: + - key: node-role.kubernetes.io/control-plane + effect: NoSchedule - key: node-role.kubernetes.io/master effect: NoSchedule serviceAccountName: elastic-agent-standalone diff --git a/deploy/kubernetes/elastic-agent-standalone/elastic-agent-standalone-daemonset.yaml b/deploy/kubernetes/elastic-agent-standalone/elastic-agent-standalone-daemonset.yaml index 0bf131ec8ea..3205b13bf88 100644 --- a/deploy/kubernetes/elastic-agent-standalone/elastic-agent-standalone-daemonset.yaml +++ b/deploy/kubernetes/elastic-agent-standalone/elastic-agent-standalone-daemonset.yaml @@ -14,9 +14,11 @@ spec: labels: app: elastic-agent-standalone spec: - # Tolerations are needed to run Elastic Agent on Kubernetes master nodes. - # Agents running on master nodes collect metrics from the control plane components (scheduler, controller manager) of Kubernetes + # Tolerations are needed to run Elastic Agent on Kubernetes control-plane nodes. + # Agents running on control-plane nodes collect metrics from the control plane components (scheduler, controller manager) of Kubernetes tolerations: + - key: node-role.kubernetes.io/control-plane + effect: NoSchedule - key: node-role.kubernetes.io/master effect: NoSchedule serviceAccountName: elastic-agent-standalone