Skip to content

Non-parseable container policies cannot be deleted

Summary

Once a non-cilium container policy is created, it cannot be deleted

Steps to reproduce

  1. Follow the Protect Onboarding task to be able to create network policies in kubernetes/cilium
  2. Navigate to Security & Compliance => Policies
  3. Create a new non-cilium container (network) policy
kind: NetworkPolicy
metadata:
  name: custom-default-deny-ingress
  namespace: cnp-alert-demo-5538634-production
spec:
  podSelector: {}
  policyTypes:
  - Ingress
  ingress: 
  egress: 
  1. Select the policy and click Edit policy in the sidebar
  2. Click the Delete policy button and confirm

Example Project

https://staging.gitlab.com/defend-team-test/cnp-alert-demo/-/security/policies

What is the current bug behavior?

The policy is NOT deleted and the user is NOT navigated to the policies list

What is the expected correct behavior?

The policy is deleted and the user is navigated to the policies list

Relevant logs and/or screenshots

image

Possible fixes

  • frontend there is something wrong with the parsing of the yaml in the frontend
Edited by Alexander Turinske