@@ -164,7 +164,7 @@ const (
164
164
// WebhookDescription provides details to OLM about required webhooks
165
165
// +k8s:openapi-gen=true
166
166
type WebhookDescription struct {
167
- Name string `json:"name "`
167
+ GenerateName string `json:"generateName "`
168
168
Type WebhookAdmissionType `json:"type"`
169
169
DeploymentName string `json:"deploymentName,omitempty"`
170
170
ContainerPort int32 `json:"containerPort,omitempty"`
@@ -180,9 +180,9 @@ type WebhookDescription struct {
180
180
}
181
181
182
182
// GetValidatingWebhook returns a ValidatingWebhook generated from the WebhookDescription
183
- func (w * WebhookDescription ) GetValidatingWebhook (namespace string , namespaceSelector * metav1.LabelSelector , caBundle []byte ) admissionregistrationv1.ValidatingWebhook {
183
+ func (w * WebhookDescription ) GetValidatingWebhook (name , namespace string , namespaceSelector * metav1.LabelSelector , caBundle []byte ) admissionregistrationv1.ValidatingWebhook {
184
184
return admissionregistrationv1.ValidatingWebhook {
185
- Name : w . Name ,
185
+ Name : name ,
186
186
Rules : w .Rules ,
187
187
FailurePolicy : w .FailurePolicy ,
188
188
MatchPolicy : w .MatchPolicy ,
@@ -203,9 +203,9 @@ func (w *WebhookDescription) GetValidatingWebhook(namespace string, namespaceSel
203
203
}
204
204
205
205
// GetMutatingWebhook returns a MutatingWebhook generated from the WebhookDescription
206
- func (w * WebhookDescription ) GetMutatingWebhook (namespace string , namespaceSelector * metav1.LabelSelector , caBundle []byte ) admissionregistrationv1.MutatingWebhook {
206
+ func (w * WebhookDescription ) GetMutatingWebhook (name , namespace string , namespaceSelector * metav1.LabelSelector , caBundle []byte ) admissionregistrationv1.MutatingWebhook {
207
207
return admissionregistrationv1.MutatingWebhook {
208
- Name : w . Name ,
208
+ Name : name ,
209
209
Rules : w .Rules ,
210
210
FailurePolicy : w .FailurePolicy ,
211
211
MatchPolicy : w .MatchPolicy ,
0 commit comments