Skip to content

Commit

Permalink
chore: Cleanup error logging when can't delete webhook
Browse files Browse the repository at this point in the history
We were using the wrong format string.

Signed-off-by: justinsb <[email protected]>
  • Loading branch information
justinsb committed Jan 26, 2024
1 parent 9d58c99 commit d40b73a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion porch/pkg/apiserver/webhooks.go
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ func createValidatingWebhook(ctx context.Context, caCert []byte) error {
}

if err := kubeClient.AdmissionregistrationV1().ValidatingWebhookConfigurations().Delete(ctx, validationCfgName, metav1.DeleteOptions{}); err != nil {
klog.Error("failed to delete existing webhook: %w", err)
klog.Warningf("failed to delete existing webhook: %v", err)
}

if _, err := kubeClient.AdmissionregistrationV1().ValidatingWebhookConfigurations().Create(ctx, validateConfig,
Expand Down

0 comments on commit d40b73a

Please sign in to comment.