Skip to content
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

Bug: Network policies with same name are displayed incorrectly #91

Closed
kyrbrbik opened this issue Dec 29, 2023 · 2 comments
Closed

Bug: Network policies with same name are displayed incorrectly #91

kyrbrbik opened this issue Dec 29, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@kyrbrbik
Copy link

When you create a multiple network policies with the same name but in different namespaces they should be limited to the namespace but they are shown incorrectly in the cluster map.

Example policy

apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
  name: allow-unknown-app-5000-tcp-nfpol
  namespace: test
spec:
  podSelector:
    matchLabels: {}
  policyTypes:
    - Ingress
    - Egress
  ingress:
    - from: []
      ports:
        - protocol: TCP
          port: 5000
  egress:
    - to:
        - ipBlock:
            cidr: 0.0.0.0/0

If there is another policy with the same name for example in namespace test2 all of the pods across the two namespaces that are withing the policy scope will be linked in the cluster map to only one of these policies.

@deggja deggja added the bug Something isn't working label Dec 29, 2023
@deggja
Copy link
Owner

deggja commented Dec 29, 2023

Thank you for reporting this. I will look into implementing a fix asap.

@deggja deggja closed this as completed in 17a67fb Dec 30, 2023
deggja added a commit that referenced this issue Dec 30, 2023
feat: added fix for #91 #patch
@deggja
Copy link
Owner

deggja commented Dec 30, 2023

@kyrbrbik implemented a fix that should resolve this issue. Feel free to test and verify that it works for the newest version!

deggja added a commit that referenced this issue May 31, 2024
Signed-off-by: deggja <danieldagfinrud@gmail.com>
deggja added a commit that referenced this issue May 31, 2024
feat: added fix for #91 #patch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants