Closed vie-serendipity closed 2 months ago
@vie-serendipity yes, I agree with you that yurtappset webhook should validate the deployment template instead of K8s native validation.
/assign @vie-serendipity
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
What would you like to be added: It is necessary to add related validation about yurtappset. Like native kubernetes resources, add validation of yurtappset created by users into webhook.
Why is this needed: First, kubernetes do validation about native resources in the webhook. It is natural to extend this style. Second, it is complicated to handle problems caused by invalid resources which may be produced by users. Subsequently, related controllerrevision handling will be tricky. We have to check whether it is invalid. https://github.com/openyurtio/openyurt/blob/34b14ccadfe26b8956144d21ec62a79a3aef1760/pkg/yurtmanager/controller/yurtappset/yurtappset_controller.go#L465 Finally, It is also unreasonable that a user need to check conditions of status after creating an invalid resource instead of just failing to create it.
others /kind feature