Skip to content

fix: Clean up MetalLB pod security standards labels #807

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

Merged
merged 1 commit into from
Jul 16, 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
Expand Up @@ -35,9 +35,8 @@ const (
// These labels allow the MetalLB speaker pod to obtain elevated permissions,
// which it requires in order to perform its network functionalities.
var podSecurityReleaseNamespaceLabels = map[string]string{
"pod-security.kubernetes.io/enforce": "privileged",
"pod-security.kubernetes.io/audit": "privileged",
"pod-security.kubernetes.io/warn": "privileged",
"pod-security.kubernetes.io/enforce": "privileged",
"pod-security.kubernetes.io/enforce-version": "latest",
}

type Config struct {
Expand Down
3 changes: 1 addition & 2 deletions pkg/handlers/utils/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,7 @@ func EnsureNamespaceWithName(ctx context.Context, c ctrlclient.Client, name stri
func EnsureNamespaceWithMetadata(ctx context.Context,
c ctrlclient.Client,
name string,
labels,
annotations map[string]string,
labels, annotations map[string]string,
) error {
ns := &corev1.Namespace{
TypeMeta: metav1.TypeMeta{
Expand Down
Loading