Skip to content

Commit 54d9a77

Browse files
committed
add clusterclaimconfig type
Signed-off-by: Omar Farag <[email protected]>
1 parent b4fb4a6 commit 54d9a77

5 files changed

+89
-0
lines changed

Diff for: crdsv1beta1/0001_00_operator.open-cluster-management.io_klusterlets.crd.yaml

+16
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,22 @@ spec:
3030
description: Spec represents the desired deployment configuration of Klusterlet agent.
3131
type: object
3232
properties:
33+
clusterClaimConfiguration:
34+
description: ClusterClaimConfiguration represents the configuration of ClusterClaim Effective only when the `ClusterClaim` feature gate is enabled.
35+
type: object
36+
required:
37+
- maxCustomClusterClaims
38+
properties:
39+
maxCustomClusterClaims:
40+
description: Maximum number of custom ClusterClaims allowed.
41+
type: integer
42+
format: int32
43+
default: 20
44+
reservedClusterClaimSuffixes:
45+
description: Custom suffixes for reserved ClusterClaims.
46+
type: array
47+
items:
48+
type: string
3349
clusterName:
3450
description: ClusterName is the name of the managed cluster to be created on hub. The Klusterlet agent generates a random name if it is not set, or discovers the appropriate cluster name on OpenShift.
3551
type: string

Diff for: operator/v1/0000_00_operator.open-cluster-management.io_klusterlets.crd.yaml

+18
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,24 @@ spec:
4343
description: Spec represents the desired deployment configuration of Klusterlet
4444
agent.
4545
properties:
46+
clusterClaimConfiguration:
47+
description: |-
48+
ClusterClaimConfiguration represents the configuration of ClusterClaim
49+
Effective only when the `ClusterClaim` feature gate is enabled.
50+
properties:
51+
maxCustomClusterClaims:
52+
default: 20
53+
description: Maximum number of custom ClusterClaims allowed.
54+
format: int32
55+
type: integer
56+
reservedClusterClaimSuffixes:
57+
description: Custom suffixes for reserved ClusterClaims.
58+
items:
59+
type: string
60+
type: array
61+
required:
62+
- maxCustomClusterClaims
63+
type: object
4664
clusterName:
4765
description: |-
4866
ClusterName is the name of the managed cluster to be created on hub.

Diff for: operator/v1/types_klusterlet.go

+18
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,24 @@ type KlusterletSpec struct {
9999
// is not available on the managed cluster.
100100
// +optional
101101
PriorityClassName string `json:"priorityClassName,omitempty"`
102+
103+
// ClusterClaimConfiguration represents the configuration of ClusterClaim
104+
// Effective only when the `ClusterClaim` feature gate is enabled.
105+
// +optional
106+
ClusterClaimConfiguration *ClusterClaimConfiguration `json:"clusterClaimConfiguration,omitempty"`
107+
}
108+
109+
// ClusterClaimConfiguration represents the configuration of ClusterClaim
110+
type ClusterClaimConfiguration struct {
111+
// Maximum number of custom ClusterClaims allowed.
112+
// +kubebuilder:validation:Required
113+
// +kubebuilder:default:=20
114+
// +required
115+
MaxCustomClusterClaims int32 `json:"maxCustomClusterClaims"`
116+
117+
// Custom suffixes for reserved ClusterClaims.
118+
// +optional
119+
ReservedClusterClaimSuffixes []string `json:"reservedClusterClaimSuffixes,omitempty"`
102120
}
103121

104122
// ServerURL represents the apiserver url and ca bundle that is accessible externally

Diff for: operator/v1/zz_generated.deepcopy.go

+26
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: operator/v1/zz_generated.swagger_doc_generated.go

+11
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)