Closed mpartel closed 3 years ago
Workaround: since maya doesn't overwrite the config if it exists, and since it appears there are no side-effects, it seems safe to modify the config after it appears.
@mpartel i have tried to run the --dry-run command, but not getting any error, can you share the k8s version you are trying ?
$ kubectl apply --dry-run -f cstor-pvc.yaml
persistentvolumeclaim/cstor-test created (dry run)
Workaround: since maya doesn't overwrite the config if it exists, and since it appears there are no side-effects, it seems safe to modify the config after it appears.
Yes , there is no side-effects.
It was either 1.19.3 or 1.19.4
Ok , i think you already tried by setting the SideEffects: None
and it should work fine. I am going to raise a PR with that change anyways. thanks
Yeah, I've seen no problems having set that manually :+1: Thanks!
Description
When running
kubectl diff
orkubectl apply --dry-run
on a config that defines aPersistentVolumeClaim
, I get this error:admission webhook "admission-webhook.openebs.io" does not support dry run
Possible Solution
You can mark the ValidatingWebhook resource that OpenEBS installs in
webhook/configuration.go
assideEffects: None
orNoneOnDryRun
, assuming the webhook indeed has no side-effects.I can make a PR if that helps, but I'd prefer if a dev could tell me whether the webhook has no side-effects rather than reading through all that the code myself.