Skip to content

Does NetworkPolicies in K3s (with Kuberouter) supporting external Networktraffic? #11097

Answered by brandond
janbaer asked this question in Q&A
Discussion options

You must be logged in to vote

As noted in the upstream docs:

ipBlock: This selects particular IP CIDR ranges to allow as ingress sources or egress destinations. These should be cluster-external IPs, since Pod IPs are ephemeral and unpredictable.

Cluster ingress and egress mechanisms often require rewriting the source or destination IP of packets. In cases where this happens, it is not defined whether this happens before or after NetworkPolicy processing, and the behavior may be different for different combinations of network plugin, cloud provider, Service implementation, etc.

IP blocks are not meant to be used to target traffic from nodes. For example when using the flannel CNI plugin, traffic from a node to pods o…

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@brandond
Comment options

Answer selected by janbaer
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants