vm: mutating webhooks: fix machine type on UPDATE
There is no known valid semantic for resetting the machine type
to "" (nil) for an existing VM. The only valid meaning is
"reset to kubevirt defaults", which is we enforce with this patch.
@@ -789,6 +789,7 @@ func (app *virtAPIApp) mutatingWebhooks() []admissionregistrationv1beta1.Webhook
Rules: []admissionregistrationv1beta1.RuleWithOperations{{
Operations: []admissionregistrationv1beta1.OperationType{
admissionregistrationv1beta1.Create,
+ admissionregistrationv1beta1.Update,
},
Rule: admissionregistrationv1beta1.Rule{
APIGroups: []string{v1.GroupName},
