From 8df21d8b5dd43a97233d3391ef2783d1fc182b29 Mon Sep 17 00:00:00 2001 From: Dale Haiducek <19750917+dhaiducek@users.noreply.github.com> Date: Thu, 9 Nov 2023 13:58:48 -0500 Subject: [PATCH] Deploy webhook config for subadmin workarounds (#393) Without the webhook, the subscription operator would not detect subscription admins. Signed-off-by: Dale Haiducek <19750917+dhaiducek@users.noreply.github.com> --- pkg/cmd/install/hubaddon/exec.go | 1 + .../scenario/addon/appmgr/mutatingwebhookconfiguration.yaml | 5 +++++ 2 files changed, 6 insertions(+) create mode 100644 pkg/cmd/install/hubaddon/scenario/addon/appmgr/mutatingwebhookconfiguration.yaml diff --git a/pkg/cmd/install/hubaddon/exec.go b/pkg/cmd/install/hubaddon/exec.go index ec9ebcf53..06a8ce476 100644 --- a/pkg/cmd/install/hubaddon/exec.go +++ b/pkg/cmd/install/hubaddon/exec.go @@ -104,6 +104,7 @@ func (o *Options) runWithClient() error { "addon/appmgr/service_account.yaml", "addon/appmgr/service_metrics.yaml", "addon/appmgr/service_operator.yaml", + "addon/appmgr/mutatingwebhookconfiguration.yaml", } err := r.Apply(scenario.Files, o.values, files...) diff --git a/pkg/cmd/install/hubaddon/scenario/addon/appmgr/mutatingwebhookconfiguration.yaml b/pkg/cmd/install/hubaddon/scenario/addon/appmgr/mutatingwebhookconfiguration.yaml new file mode 100644 index 000000000..aa2fe6190 --- /dev/null +++ b/pkg/cmd/install/hubaddon/scenario/addon/appmgr/mutatingwebhookconfiguration.yaml @@ -0,0 +1,5 @@ +# Copyright Contributors to the Open Cluster Management project +apiVersion: admissionregistration.k8s.io/v1 +kind: MutatingWebhookConfiguration +metadata: + name: ocm-mutating-webhook