|
58 | 58 | properties:
|
59 | 59 | install:
|
60 | 60 | description: |-
|
61 |
| - install is a required field used to configure the installation options |
62 |
| - for the ClusterExtension such as the installation namespace, |
63 |
| - the service account and the pre-flight check configuration. |
64 |
| -
|
65 |
| - Below is a minimal example of an installation definition (in yaml): |
66 |
| - install: |
67 |
| - namespace: example-namespace |
68 |
| - serviceAccount: |
69 |
| - name: example-sa |
| 61 | + install is an optional field used to configure the installation options |
| 62 | + for the ClusterExtension such as the pre-flight check configuration. |
70 | 63 | properties:
|
71 |
| - namespace: |
72 |
| - description: |- |
73 |
| - namespace designates the kubernetes Namespace where bundle content |
74 |
| - for the package, referenced in the 'packageName' field, will be applied and the necessary |
75 |
| - service account can be found. |
76 |
| - The bundle may contain cluster-scoped resources or resources that are |
77 |
| - applied to other Namespaces. This Namespace is expected to exist. |
78 |
| -
|
79 |
| - namespace is required, immutable, and follows the DNS label standard |
80 |
| - as defined in [RFC 1123]. It must contain only lowercase alphanumeric characters or hyphens (-), |
81 |
| - start and end with an alphanumeric character, and be no longer than 63 characters |
82 |
| -
|
83 |
| - [RFC 1123]: https://tools.ietf.org/html/rfc1123 |
84 |
| - maxLength: 63 |
85 |
| - type: string |
86 |
| - x-kubernetes-validations: |
87 |
| - - message: namespace is immutable |
88 |
| - rule: self == oldSelf |
89 |
| - - message: namespace must be a valid DNS1123 label. It must contain |
90 |
| - only lowercase alphanumeric characters or hyphens (-), start |
91 |
| - and end with an alphanumeric character, and be no longer than |
92 |
| - 63 characters |
93 |
| - rule: self.matches("^[a-z0-9]([-a-z0-9]*[a-z0-9])?$") |
94 | 64 | preflight:
|
95 | 65 | description: |-
|
96 | 66 | preflight is an optional field that can be used to configure the checks that are
|
@@ -133,58 +103,77 @@ spec:
|
133 | 103 | - message: at least one of [crdUpgradeSafety] are required when
|
134 | 104 | preflight is specified
|
135 | 105 | rule: has(self.crdUpgradeSafety)
|
136 |
| - serviceAccount: |
| 106 | + type: object |
| 107 | + x-kubernetes-validations: |
| 108 | + - message: at least one of [preflight] are required when install is |
| 109 | + specified |
| 110 | + rule: has(self.preflight) |
| 111 | + namespace: |
| 112 | + description: |- |
| 113 | + namespace is a reference to a Kubernetes namespace. |
| 114 | + This is the namespace in which the provided ServiceAccount must exist. |
| 115 | + It also designates the default namespace where namespace-scoped resources |
| 116 | + for the extension are applied to the cluster. |
| 117 | + Some extensions may contain namespace-scoped resources to be applied in other namespaces. |
| 118 | + This namespace must exist. |
| 119 | +
|
| 120 | + namespace is required, immutable, and follows the DNS label standard |
| 121 | + as defined in [RFC 1123]. It must contain only lowercase alphanumeric characters or hyphens (-), |
| 122 | + start and end with an alphanumeric character, and be no longer than 63 characters |
| 123 | +
|
| 124 | + [RFC 1123]: https://tools.ietf.org/html/rfc1123 |
| 125 | + maxLength: 63 |
| 126 | + type: string |
| 127 | + x-kubernetes-validations: |
| 128 | + - message: namespace is immutable |
| 129 | + rule: self == oldSelf |
| 130 | + - message: namespace must be a valid DNS1123 label |
| 131 | + rule: self.matches("^[a-z0-9]([-a-z0-9]*[a-z0-9])?$") |
| 132 | + serviceAccount: |
| 133 | + description: |- |
| 134 | + serviceAccount is a reference to a ServiceAccount used to perform all interactions |
| 135 | + with the cluster that are required to manage the extension. |
| 136 | + The ServiceAccount must be configured with the necessary permissions to perform these interactions. |
| 137 | + The ServiceAccount must exist in the namespace referenced in the spec. |
| 138 | + serviceAccount is required. |
| 139 | + properties: |
| 140 | + name: |
137 | 141 | description: |-
|
138 |
| - serviceAccount is a required reference to a ServiceAccount that exists |
139 |
| - in the installNamespace which is used to install and |
140 |
| - manage the content for the package specified in the packageName field. |
141 |
| -
|
142 |
| - In order to successfully install and manage the content for the package, |
143 |
| - the ServiceAccount provided via this field should be configured with the |
144 |
| - appropriate permissions to perform the necessary operations on all the |
145 |
| - resources that are included in the bundle of content being applied. |
146 |
| - properties: |
147 |
| - name: |
148 |
| - description: |- |
149 |
| - name is a required, immutable reference to the name of the ServiceAccount |
150 |
| - to be used for installation and management of the content for the package |
151 |
| - specified in the packageName field. |
| 142 | + name is a required, immutable reference to the name of the ServiceAccount |
| 143 | + to be used for installation and management of the content for the package |
| 144 | + specified in the packageName field. |
152 | 145 |
|
153 |
| - This ServiceAccount must exist in the installNamespace. |
| 146 | + This ServiceAccount must exist in the installNamespace. |
154 | 147 |
|
155 |
| - name follows the DNS subdomain standard as defined in [RFC 1123]. |
156 |
| - It must contain only lowercase alphanumeric characters, |
157 |
| - hyphens (-) or periods (.), start and end with an alphanumeric character, |
158 |
| - and be no longer than 253 characters. |
| 148 | + name follows the DNS subdomain standard as defined in [RFC 1123]. |
| 149 | + It must contain only lowercase alphanumeric characters, |
| 150 | + hyphens (-) or periods (.), start and end with an alphanumeric character, |
| 151 | + and be no longer than 253 characters. |
159 | 152 |
|
160 |
| - Some examples of valid values are: |
161 |
| - - some-serviceaccount |
162 |
| - - 123-serviceaccount |
163 |
| - - 1-serviceaccount-2 |
164 |
| - - someserviceaccount |
165 |
| - - some.serviceaccount |
| 153 | + Some examples of valid values are: |
| 154 | + - some-serviceaccount |
| 155 | + - 123-serviceaccount |
| 156 | + - 1-serviceaccount-2 |
| 157 | + - someserviceaccount |
| 158 | + - some.serviceaccount |
166 | 159 |
|
167 |
| - Some examples of invalid values are: |
168 |
| - - -some-serviceaccount |
169 |
| - - some-serviceaccount- |
| 160 | + Some examples of invalid values are: |
| 161 | + - -some-serviceaccount |
| 162 | + - some-serviceaccount- |
170 | 163 |
|
171 |
| - [RFC 1123]: https://tools.ietf.org/html/rfc1123 |
172 |
| - maxLength: 253 |
173 |
| - type: string |
174 |
| - x-kubernetes-validations: |
175 |
| - - message: name is immutable |
176 |
| - rule: self == oldSelf |
177 |
| - - message: name must be a valid DNS1123 subdomain. It must |
178 |
| - contain only lowercase alphanumeric characters, hyphens |
179 |
| - (-) or periods (.), start and end with an alphanumeric |
180 |
| - character, and be no longer than 253 characters |
181 |
| - rule: self.matches("^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$") |
182 |
| - required: |
183 |
| - - name |
184 |
| - type: object |
| 164 | + [RFC 1123]: https://tools.ietf.org/html/rfc1123 |
| 165 | + maxLength: 253 |
| 166 | + type: string |
| 167 | + x-kubernetes-validations: |
| 168 | + - message: name is immutable |
| 169 | + rule: self == oldSelf |
| 170 | + - message: name must be a valid DNS1123 subdomain. It must contain |
| 171 | + only lowercase alphanumeric characters, hyphens (-) or periods |
| 172 | + (.), start and end with an alphanumeric character, and be |
| 173 | + no longer than 253 characters |
| 174 | + rule: self.matches("^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$") |
185 | 175 | required:
|
186 |
| - - namespace |
187 |
| - - serviceAccount |
| 176 | + - name |
188 | 177 | type: object
|
189 | 178 | source:
|
190 | 179 | description: |-
|
@@ -468,7 +457,8 @@ spec:
|
468 | 457 | rule: 'has(self.sourceType) && self.sourceType == ''Catalog'' ?
|
469 | 458 | has(self.catalog) : !has(self.catalog)'
|
470 | 459 | required:
|
471 |
| - - install |
| 460 | + - namespace |
| 461 | + - serviceAccount |
472 | 462 | - source
|
473 | 463 | type: object
|
474 | 464 | status:
|
|
0 commit comments