Skip to content

Commit 57533ab

Browse files
committed
Support default mode webhook networking configuration
Signed-off-by: Ben Perry <[email protected]>
1 parent 27fc65e commit 57533ab

24 files changed

+590
-79
lines changed

deploy/cluster-manager/chart/cluster-manager/crds/0000_01_operator.open-cluster-management.io_clustermanagers.crd.yaml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,71 @@ spec:
9191
DeployOption contains the options of deploying a cluster-manager
9292
Default mode is used if DeployOption is not set.
9393
properties:
94+
default:
95+
description: Default includes configurations for clustermanager
96+
in the Default mode
97+
properties:
98+
registrationWebhookConfiguration:
99+
description: RegistrationWebhookConfiguration represents the
100+
customized webhook-server configuration of registration.
101+
properties:
102+
healthProbeBindAddress:
103+
default: :8000
104+
description: |-
105+
HealthProbeBindAddress represents the healthcheck address of a webhook-server. The default value is ":8000".
106+
Healthchecks may be disabled by setting a value of "0" or "".
107+
type: string
108+
hostNetwork:
109+
description: |-
110+
HostNetwork enables running webhook pods with hostNetwork: true
111+
This may be required in some installations, such as EKS with Calico CNI,
112+
to allow the API Server to communicate with the webhook pods.
113+
type: boolean
114+
metricsBindAddress:
115+
default: :8080
116+
description: |-
117+
MetricsBindAddress represents the metrics address of a webhook-server. The default value is ":8080"
118+
Metrics may be disabled by setting a value of "0" or "".
119+
type: string
120+
port:
121+
default: 9443
122+
description: Port represents the port of a webhook-server.
123+
The default value of Port is 9443.
124+
format: int32
125+
maximum: 65535
126+
type: integer
127+
type: object
128+
workWebhookConfiguration:
129+
description: WorkWebhookConfiguration represents the customized
130+
webhook-server configuration of work.
131+
properties:
132+
healthProbeBindAddress:
133+
default: :8000
134+
description: |-
135+
HealthProbeBindAddress represents the healthcheck address of a webhook-server. The default value is ":8000".
136+
Healthchecks may be disabled by setting a value of "0" or "".
137+
type: string
138+
hostNetwork:
139+
description: |-
140+
HostNetwork enables running webhook pods with hostNetwork: true
141+
This may be required in some installations, such as EKS with Calico CNI,
142+
to allow the API Server to communicate with the webhook pods.
143+
type: boolean
144+
metricsBindAddress:
145+
default: :8080
146+
description: |-
147+
MetricsBindAddress represents the metrics address of a webhook-server. The default value is ":8080"
148+
Metrics may be disabled by setting a value of "0" or "".
149+
type: string
150+
port:
151+
default: 9443
152+
description: Port represents the port of a webhook-server.
153+
The default value of Port is 9443.
154+
format: int32
155+
maximum: 65535
156+
type: integer
157+
type: object
158+
type: object
94159
hosted:
95160
description: Hosted includes configurations we need for clustermanager
96161
in the Hosted mode.

deploy/cluster-manager/config/crds/0000_01_operator.open-cluster-management.io_clustermanagers.crd.yaml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,71 @@ spec:
9191
DeployOption contains the options of deploying a cluster-manager
9292
Default mode is used if DeployOption is not set.
9393
properties:
94+
default:
95+
description: Default includes configurations for clustermanager
96+
in the Default mode
97+
properties:
98+
registrationWebhookConfiguration:
99+
description: RegistrationWebhookConfiguration represents the
100+
customized webhook-server configuration of registration.
101+
properties:
102+
healthProbeBindAddress:
103+
default: :8000
104+
description: |-
105+
HealthProbeBindAddress represents the healthcheck address of a webhook-server. The default value is ":8000".
106+
Healthchecks may be disabled by setting a value of "0" or "".
107+
type: string
108+
hostNetwork:
109+
description: |-
110+
HostNetwork enables running webhook pods with hostNetwork: true
111+
This may be required in some installations, such as EKS with Calico CNI,
112+
to allow the API Server to communicate with the webhook pods.
113+
type: boolean
114+
metricsBindAddress:
115+
default: :8080
116+
description: |-
117+
MetricsBindAddress represents the metrics address of a webhook-server. The default value is ":8080"
118+
Metrics may be disabled by setting a value of "0" or "".
119+
type: string
120+
port:
121+
default: 9443
122+
description: Port represents the port of a webhook-server.
123+
The default value of Port is 9443.
124+
format: int32
125+
maximum: 65535
126+
type: integer
127+
type: object
128+
workWebhookConfiguration:
129+
description: WorkWebhookConfiguration represents the customized
130+
webhook-server configuration of work.
131+
properties:
132+
healthProbeBindAddress:
133+
default: :8000
134+
description: |-
135+
HealthProbeBindAddress represents the healthcheck address of a webhook-server. The default value is ":8000".
136+
Healthchecks may be disabled by setting a value of "0" or "".
137+
type: string
138+
hostNetwork:
139+
description: |-
140+
HostNetwork enables running webhook pods with hostNetwork: true
141+
This may be required in some installations, such as EKS with Calico CNI,
142+
to allow the API Server to communicate with the webhook pods.
143+
type: boolean
144+
metricsBindAddress:
145+
default: :8080
146+
description: |-
147+
MetricsBindAddress represents the metrics address of a webhook-server. The default value is ":8080"
148+
Metrics may be disabled by setting a value of "0" or "".
149+
type: string
150+
port:
151+
default: 9443
152+
description: Port represents the port of a webhook-server.
153+
The default value of Port is 9443.
154+
format: int32
155+
maximum: 65535
156+
type: integer
157+
type: object
158+
type: object
94159
hosted:
95160
description: Hosted includes configurations we need for clustermanager
96161
in the Hosted mode.

deploy/cluster-manager/olm-catalog/latest/manifests/cluster-manager.clusterserviceversion.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ metadata:
5959
categories: Integration & Delivery,OpenShift Optional
6060
certified: "false"
6161
containerImage: quay.io/open-cluster-management/registration-operator:latest
62-
createdAt: "2025-05-29T02:56:45Z"
62+
createdAt: "2025-06-12T23:20:27Z"
6363
description: Manages the installation and upgrade of the ClusterManager.
6464
operators.operatorframework.io/builder: operator-sdk-v1.32.0
6565
operators.operatorframework.io/project_layout: go.kubebuilder.io/v3

deploy/cluster-manager/olm-catalog/latest/manifests/operator.open-cluster-management.io_clustermanagers.yaml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,71 @@ spec:
9191
DeployOption contains the options of deploying a cluster-manager
9292
Default mode is used if DeployOption is not set.
9393
properties:
94+
default:
95+
description: Default includes configurations for clustermanager
96+
in the Default mode
97+
properties:
98+
registrationWebhookConfiguration:
99+
description: RegistrationWebhookConfiguration represents the
100+
customized webhook-server configuration of registration.
101+
properties:
102+
healthProbeBindAddress:
103+
default: :8000
104+
description: |-
105+
HealthProbeBindAddress represents the healthcheck address of a webhook-server. The default value is ":8000".
106+
Healthchecks may be disabled by setting a value of "0" or "".
107+
type: string
108+
hostNetwork:
109+
description: |-
110+
HostNetwork enables running webhook pods with hostNetwork: true
111+
This may be required in some installations, such as EKS with Calico CNI,
112+
to allow the API Server to communicate with the webhook pods.
113+
type: boolean
114+
metricsBindAddress:
115+
default: :8080
116+
description: |-
117+
MetricsBindAddress represents the metrics address of a webhook-server. The default value is ":8080"
118+
Metrics may be disabled by setting a value of "0" or "".
119+
type: string
120+
port:
121+
default: 9443
122+
description: Port represents the port of a webhook-server.
123+
The default value of Port is 9443.
124+
format: int32
125+
maximum: 65535
126+
type: integer
127+
type: object
128+
workWebhookConfiguration:
129+
description: WorkWebhookConfiguration represents the customized
130+
webhook-server configuration of work.
131+
properties:
132+
healthProbeBindAddress:
133+
default: :8000
134+
description: |-
135+
HealthProbeBindAddress represents the healthcheck address of a webhook-server. The default value is ":8000".
136+
Healthchecks may be disabled by setting a value of "0" or "".
137+
type: string
138+
hostNetwork:
139+
description: |-
140+
HostNetwork enables running webhook pods with hostNetwork: true
141+
This may be required in some installations, such as EKS with Calico CNI,
142+
to allow the API Server to communicate with the webhook pods.
143+
type: boolean
144+
metricsBindAddress:
145+
default: :8080
146+
description: |-
147+
MetricsBindAddress represents the metrics address of a webhook-server. The default value is ":8080"
148+
Metrics may be disabled by setting a value of "0" or "".
149+
type: string
150+
port:
151+
default: 9443
152+
description: Port represents the port of a webhook-server.
153+
The default value of Port is 9443.
154+
format: int32
155+
maximum: 65535
156+
type: integer
157+
type: object
158+
type: object
94159
hosted:
95160
description: Hosted includes configurations we need for clustermanager
96161
in the Hosted mode.

deploy/klusterlet/olm-catalog/latest/manifests/klusterlet.clusterserviceversion.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ metadata:
3131
categories: Integration & Delivery,OpenShift Optional
3232
certified: "false"
3333
containerImage: quay.io/open-cluster-management/registration-operator:latest
34-
createdAt: "2025-05-29T02:56:45Z"
34+
createdAt: "2025-06-12T23:20:27Z"
3535
description: Manages the installation and upgrade of the Klusterlet.
3636
operators.operatorframework.io/builder: operator-sdk-v1.32.0
3737
operators.operatorframework.io/project_layout: go.kubebuilder.io/v3

go.mod

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ module open-cluster-management.io/ocm
22

33
go 1.23.6
44

5+
replace open-cluster-management.io/api => github.com/bhperry/ocm-api v0.0.0-20250612225613-ffa7865df0a9
6+
57
require (
68
github.com/aws/aws-sdk-go-v2 v1.36.3
79
github.com/aws/aws-sdk-go-v2/config v1.29.14

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,8 @@ github.com/aws/smithy-go v1.22.2 h1:6D9hW43xKFrRx/tXXfAlIZc4JI+yQe6snnWcQyxSyLQ=
5858
github.com/aws/smithy-go v1.22.2/go.mod h1:irrKGvNn1InZwb2d7fkIRNucdfwR8R+Ts3wxYa/cJHg=
5959
github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM=
6060
github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw=
61+
github.com/bhperry/ocm-api v0.0.0-20250612225613-ffa7865df0a9 h1:Cs8jDa7M7sGmQA3OmGYsnn+yD/aytxyhYym6qtZHsVs=
62+
github.com/bhperry/ocm-api v0.0.0-20250612225613-ffa7865df0a9/go.mod h1:/OeqXycNBZQoe3WG6ghuWsMgsKGuMZrK8ZpsU6gWL0Y=
6163
github.com/blang/semver/v4 v4.0.0 h1:1PFHFE6yCCTv8C1TeyNNarDzntLi7wMI5i/pzqYIsAM=
6264
github.com/blang/semver/v4 v4.0.0/go.mod h1:IbckMUScFkM3pff0VJDNKRiT6TG/YpiHIM2yvyW5YoQ=
6365
github.com/bwmarrin/snowflake v0.3.0 h1:xm67bEhkKh6ij1790JB83OujPR5CzNe8QuQqAgISZN0=
@@ -491,8 +493,6 @@ k8s.io/utils v0.0.0-20241104100929-3ea5e8cea738 h1:M3sRQVHv7vB20Xc2ybTt7ODCeFj6J
491493
k8s.io/utils v0.0.0-20241104100929-3ea5e8cea738/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0=
492494
open-cluster-management.io/addon-framework v0.12.1-0.20250407131028-9d436ffc2da7 h1:oLu9ag44Msf56Hb19b/b+UTNq0J2l9rhlBQ1gh7izCU=
493495
open-cluster-management.io/addon-framework v0.12.1-0.20250407131028-9d436ffc2da7/go.mod h1:7AEw1Sq9UEWpQGTU8zV1XPNkFRBYPbyBh8tfhISV++s=
494-
open-cluster-management.io/api v0.16.2-0.20250530014337-5880b0cf7dab h1:OGuw8WQOnvyPIwoDhWr+6bDgn8EwcR0SdNdL36WkBwE=
495-
open-cluster-management.io/api v0.16.2-0.20250530014337-5880b0cf7dab/go.mod h1:/OeqXycNBZQoe3WG6ghuWsMgsKGuMZrK8ZpsU6gWL0Y=
496496
open-cluster-management.io/sdk-go v0.16.1-0.20250530024739-3724a1e691fe h1:Y0FNpLz9msY7iz59lQxV+p2pY9aid0nzQ3IOMYxjHiU=
497497
open-cluster-management.io/sdk-go v0.16.1-0.20250530024739-3724a1e691fe/go.mod h1:n89YVVoi5zm3KVpOyVMmTdD4rGOVSsykUtu7Ol3do3M=
498498
sigs.k8s.io/about-api v0.0.0-20250131010323-518069c31c03 h1:1ShFiMjGQOR/8jTBkmZrk1gORxnvMwm1nOy2/DbHg4U=

manifests/cluster-manager/hub/cluster-manager-registration-webhook-service.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,5 @@ spec:
1414
app: {{ .ClusterManagerName }}-registration-webhook
1515
ports:
1616
- name: webhook
17-
port: 9443
18-
targetPort: 9443
17+
port: {{ .RegistrationWebhook.Port }}
18+
targetPort: {{ .RegistrationWebhook.Port }}

manifests/cluster-manager/hub/cluster-manager-work-webhook-service.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,5 @@ spec:
1414
app: {{ .ClusterManagerName }}-work-webhook
1515
ports:
1616
- name: webhook
17-
port: 9443
18-
targetPort: 9443
17+
port: {{ .WorkWebhook.Port }}
18+
targetPort: {{ .WorkWebhook.Port }}

manifests/cluster-manager/hub/cluster-manager-work-webhook-validatingconfiguration.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ webhooks:
1717
namespace: {{ .ClusterManagerNamespace }}
1818
name: cluster-manager-work-webhook
1919
path: /validate-work-open-cluster-management-io-v1-manifestwork
20-
port: {{.RegistrationWebhook.Port}}
21-
caBundle: {{ .RegistrationAPIServiceCABundle }}
20+
port: {{.WorkWebhook.Port}}
21+
caBundle: {{ .WorkAPIServiceCABundle }}
2222
rules:
2323
- operations:
2424
- CREATE

0 commit comments

Comments
 (0)