policy: Fix node selector handling for local host in KCNP#44446
policy: Fix node selector handling for local host in KCNP#44446giorio94 merged 2 commits intocilium:mainfrom
Conversation
|
@jrajahalme @squeed For your attention |
|
/test |
|
Is this a behavior change? Will this cause policies that used to block not to? |
It is a bug fix, the policy should have matched on the local node, too, but it didn't. This makes Cilium pass the k8s ClusterNetworkPolicy conformance tests. Note that support for ClusterNetworkPolicy was just added last week and it is not enabled by default. |
070c283 to
f4d422b
Compare
f4d422b to
ad59498
Compare
|
/test |
746ad5b to
53511ec
Compare
|
/test |
53511ec to
ff86a48
Compare
|
I am curious how much different is kCNP in comparison to CNPs/CCNPs, but for the latter I have no objection, nor for the nodemanager changes. I can see only these changes: (new) (old) (new) which does not affect policies as localnode is always allowed to acces the corresponding pod. |
|
/test |
Head branch was pushed to by a user without write access
ff86a48 to
d9a9e29
Compare
|
I rebased the CL, that will hopefully get rid of the CI test failures. |
|
/test |
1 similar comment
|
/test |
|
Commit f7b4e62 does not match "(?m)^Signed-off-by:". Please follow instructions provided in https://docs.cilium.io/en/stable/contributing/development/contributing_guide/#developer-s-certificate-of-origin |
f7b4e62 to
2d56a74
Compare
|
Commit f7b4e62 does not match "(?m)^Signed-off-by:". Please follow instructions provided in https://docs.cilium.io/en/stable/contributing/development/contributing_guide/#developer-s-certificate-of-origin |
|
/test |
2 similar comments
|
/test |
|
/test |
2d56a74 to
169f736
Compare
Currently we only match labels on the remote node (reserved:remote-node), this expands the search to the local node, too (reserved:host). Signed-off-by: Blaz Zupan <blaz@google.com>
Signed-off-by: Blaz Zupan <blaz@google.com>
169f736 to
a12dfd8
Compare
|
/test |
Node selector in k8s ClusterNetworkPolicy is supposed to match on all nodes. The existing code only matched on remote nodes. Add a node selector that also matches the local node (i.e. the same node that the subject pod is running on).