edgelesssys / contrast

Deploy and manage confidential containers on Kubernetes
https://docs.edgeless.systems/contrast
GNU Affero General Public License v3.0
161 stars 6 forks source link

[release/v0.6] kuberesource: remove namespace when patching with empty string #467

Closed edgelessci closed 1 month ago

edgelessci commented 1 month ago

Backport of #465 to release/v0.6.

Original description:


In the emojivoto-demo deployment YAML that we released with v0.6.0, the namespace is explicitly set to the empty string. While this is valid for Kubernetes (empty string is synonym to the default namespace), genpolicy can't handle these empty strings and will enforce in the policy the literal empty string, leading to the deployment being unable to start.