From f484ae5bcbd9fe271839361fa232c0f129136dbf Mon Sep 17 00:00:00 2001 From: Ryota Sakamoto Date: Mon, 24 Feb 2025 18:45:11 +0000 Subject: [PATCH] Fix kernel version check condition in nftables proxier Signed-off-by: Ryota Sakamoto --- pkg/proxy/nftables/proxier.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/proxy/nftables/proxier.go b/pkg/proxy/nftables/proxier.go index f6907cd2f64..f31e2905449 100644 --- a/pkg/proxy/nftables/proxier.go +++ b/pkg/proxy/nftables/proxier.go @@ -320,7 +320,7 @@ func getNFTablesInterface(ipFamily v1.IPFamily) (knftables.Interface, error) { // // However, we allow the user to bypass this check by setting // `KUBE_PROXY_NFTABLES_SKIP_KERNEL_VERSION_CHECK` to anything non-empty. - if os.Getenv("KUBE_PROXY_NFTABLES_SKIP_KERNEL_VERSION_CHECK") != "" { + if os.Getenv("KUBE_PROXY_NFTABLES_SKIP_KERNEL_VERSION_CHECK") == "" { kernelVersion, err := utilkernel.GetVersion() if err != nil { return nil, fmt.Errorf("could not check kernel version: %w", err)