ahmetb / kubernetes-network-policy-recipes

Example recipes for Kubernetes Network Policies that you can just copy paste

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Doc error in 04-deny-traffic-from-other-namespaces

Eric-Fontana-Bose opened this issue · comments

You .gif has a label on the center as namespace:default and it should be namespace:secondary

I don't have the source to the .gif or I would have opened a PR.

The image needing fixing: https://github.com/ahmetb/kubernetes-network-policy-recipes/blob/master/img/4.gif

Thanks for noticing. I don't think in many cases example gifs match the actual code. GIFs are meant to illustrate use cases. In that gif, there's namespaces foo & bar, too. But in the example, they don't exist.

This repo has been very helpful. One thing worth mentioning is what/how policies are processed when you have multiple yaml files applied as different policy names in the same namespace, i assume those are logically OR'd as well.

tl;dr of network policies is:

  • if there's one rule allowing traffic, it will be allowed.
  • if there's no rule matching to the traffic, it's allowed.

I have a link to my kubecon talk in the readme, that might help you better, too.

I think instead of closing it you should then name the namespace default in the network policy and the text.