Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update labels to use kubernetes recommended labels #4722

Merged
merged 2 commits into from
Oct 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Kind can be one of:
# - breaking-change: a change to previously-documented behavior
# - deprecation: functionality that is being removed in a later release
# - bug-fix: fixes a problem in a previous version
# - enhancement: extends functionality but does not break or fix existing behavior
# - feature: new functionality
# - known-issue: problems that we are aware of in a given version
# - security: impacts on the security of a product or a user’s deployment.
# - upgrade: important information for someone upgrading from a prior version
# - other: does not fit into any of the other categories
kind: feature

# Change summary; a 80ish characters long description of the change.
summary: Update kubernetes manifests to adopt official recommended labels

# Long description; in case the summary is not enough to describe the change
# this field accommodate a description without length limits.
# NOTE: This field will be rendered only for breaking-change and known-issue kinds at the moment.
description: Update kubernetes manifests to adopt the official recommended labels. This will require a `kubectl replace` to apply as selector labels are an immutable field.

# Affected component; usually one of "elastic-agent", "fleet-server", "filebeat", "metricbeat", "auditbeat", "all", etc.
component: elastic-agent

# PR URL; optional; the PR number that added the changeset.
# If not present is automatically filled by the tooling finding the PR where this changelog fragment has been added.
# NOTE: the tooling supports backports, so it's able to fill the original PR number instead of the backport PR number.
# Please provide it if you are adding a fragment for a different PR.
pr: https://github.com/elastic/elastic-agent/pull/4722
# Issue URL; optional; the GitHub issue related to this changeset (either closes or is part of).
# If not present is automatically filled by the tooling with the issue linked to the PR number.
#issue: https://github.com/owner/repo/1234
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ metadata:
name: elastic-agent
namespace: kube-system
labels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
spec:
selector:
matchLabels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
template:
metadata:
labels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
spec:
# 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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ kind: ClusterRole
metadata:
name: elastic-agent
labels:
k8s-app: elastic-agent
app.kubernetes.io/name: elastic-agent
rules:
- apiGroups: [""]
resources:
Expand Down Expand Up @@ -75,7 +75,7 @@ metadata:
# Should be the namespace where elastic-agent is running
namespace: kube-system
labels:
k8s-app: elastic-agent
app.kubernetes.io/name: elastic-agent
rules:
- apiGroups:
- coordination.k8s.io
Expand All @@ -89,7 +89,7 @@ metadata:
name: elastic-agent-kubeadm-config
namespace: kube-system
labels:
k8s-app: elastic-agent
app.kubernetes.io/name: elastic-agent
rules:
- apiGroups: [""]
resources:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ metadata:
name: elastic-agent
namespace: kube-system
labels:
k8s-app: elastic-agent
app.kubernetes.io/name: elastic-agent
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ metadata:
name: agent-node-datastreams
namespace: kube-system
labels:
k8s-app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
data:
agent.yml: |-
outputs:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ metadata:
name: elastic-agent-standalone
namespace: kube-system
labels:
app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
spec:
selector:
matchLabels:
app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
template:
metadata:
labels:
app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
spec:
# 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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ metadata:
name: agent-node-datastreams
namespace: kube-system
labels:
k8s-app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
data:
agent.yml: |-
outputs:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ metadata:
name: agent-ksm-datastreams
namespace: kube-system
labels:
k8s-app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
data:
agent.yml: |-
outputs:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ kind: ClusterRole
metadata:
name: elastic-agent-standalone
labels:
k8s-app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
rules:
- apiGroups: [""]
resources:
Expand Down Expand Up @@ -75,7 +75,7 @@ metadata:
# Should be the namespace where elastic-agent is running
namespace: kube-system
labels:
k8s-app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
rules:
- apiGroups:
- coordination.k8s.io
Expand All @@ -89,7 +89,7 @@ metadata:
name: elastic-agent-standalone-kubeadm-config
namespace: kube-system
labels:
k8s-app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
rules:
- apiGroups: [""]
resources:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ metadata:
name: elastic-agent-standalone
namespace: kube-system
labels:
k8s-app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ metadata:
name: elastic-agent
namespace: kube-system
labels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
spec:
selector:
matchLabels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
template:
metadata:
labels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
spec:
# 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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ kind: ClusterRole
metadata:
name: elastic-agent
labels:
k8s-app: elastic-agent
app.kubernetes.io/name: elastic-agent
rules:
- apiGroups: [""]
resources:
Expand Down Expand Up @@ -75,7 +75,7 @@ metadata:
# Should be the namespace where elastic-agent is running
namespace: kube-system
labels:
k8s-app: elastic-agent
app.kubernetes.io/name: elastic-agent
rules:
- apiGroups:
- coordination.k8s.io
Expand All @@ -89,7 +89,7 @@ metadata:
name: elastic-agent-kubeadm-config
namespace: kube-system
labels:
k8s-app: elastic-agent
app.kubernetes.io/name: elastic-agent
rules:
- apiGroups: [""]
resources:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ metadata:
name: elastic-agent
namespace: kube-system
labels:
k8s-app: elastic-agent
app.kubernetes.io/name: elastic-agent
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ metadata:
name: elastic-agent
namespace: kube-system
labels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
spec:
selector:
matchLabels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
template:
metadata:
labels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
spec:
# 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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ metadata:
name: elastic-agent-standalone
namespace: kube-system
labels:
app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
spec:
selector:
matchLabels:
app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
template:
metadata:
labels:
app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
spec:
# 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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ metadata:
name: agent-node-datastreams
namespace: kube-system
labels:
k8s-app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
data:
agent.yml: |-
outputs:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ metadata:
name: agent-ksm-datastreams
namespace: kube-system
labels:
k8s-app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
data:
agent.yml: |-
outputs:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ kind: ClusterRole
metadata:
name: elastic-agent-standalone
labels:
k8s-app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
rules:
- apiGroups: [""]
resources:
Expand Down Expand Up @@ -75,7 +75,7 @@ metadata:
# Should be the namespace where elastic-agent is running
namespace: kube-system
labels:
k8s-app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
rules:
- apiGroups:
- coordination.k8s.io
Expand All @@ -89,7 +89,7 @@ metadata:
name: elastic-agent-standalone-kubeadm-config
namespace: kube-system
labels:
k8s-app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
rules:
- apiGroups: [""]
resources:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ metadata:
name: elastic-agent-standalone
namespace: kube-system
labels:
k8s-app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ metadata:
name: elastic-agent-standalone
namespace: kube-system
labels:
app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
spec:
selector:
matchLabels:
app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
template:
metadata:
labels:
app: elastic-agent-standalone
app.kubernetes.io/name: elastic-agent-standalone
spec:
# 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
Expand Down
14 changes: 7 additions & 7 deletions deploy/kubernetes/elastic-agent-managed-kubernetes.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ metadata:
name: elastic-agent
namespace: kube-system
labels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
spec:
selector:
matchLabels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
template:
metadata:
labels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
spec:
# 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
Expand Down Expand Up @@ -192,7 +192,7 @@ kind: ClusterRole
metadata:
name: elastic-agent
labels:
k8s-app: elastic-agent
app.kubernetes.io/name: elastic-agent
rules:
- apiGroups: [""]
resources:
Expand Down Expand Up @@ -264,7 +264,7 @@ metadata:
# Should be the namespace where elastic-agent is running
namespace: kube-system
labels:
k8s-app: elastic-agent
app.kubernetes.io/name: elastic-agent
rules:
- apiGroups:
- coordination.k8s.io
Expand All @@ -278,7 +278,7 @@ metadata:
name: elastic-agent-kubeadm-config
namespace: kube-system
labels:
k8s-app: elastic-agent
app.kubernetes.io/name: elastic-agent
rules:
- apiGroups: [""]
resources:
Expand All @@ -293,5 +293,5 @@ metadata:
name: elastic-agent
namespace: kube-system
labels:
k8s-app: elastic-agent
app.kubernetes.io/name: elastic-agent
---
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ metadata:
name: elastic-agent
namespace: kube-system
labels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
spec:
selector:
matchLabels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
template:
metadata:
labels:
app: elastic-agent
app.kubernetes.io/name: elastic-agent
spec:
# 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
Expand Down
Loading