Skip to content

Commit 1a35a03

Browse files
feat: handle CRD lifecycle in helm backend chart
Fixes #404 by moving CRDs to templates and guarding with crds.install flag. Signed-off-by: alokkumardalei-wq <alokkumardalei2@gmail.com>
1 parent 5d02230 commit 1a35a03

15 files changed

Lines changed: 40 additions & 1 deletion

deploy/charts/backend/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ See [values.yaml](values.yaml) for the full list of configurable parameters.
6161
| backend.tls.tlsKeyFile | string | `"/etc/kube-bind/tls/tls.key"` | Path to TLS key file inside the container |
6262
| certManager.clusterIssuer | string | `""` | Name of the ClusterIssuer to use |
6363
| certManager.enabled | bool | `false` | Enable cert-manager integration for automatic TLS certificates |
64+
| crds.install | bool | `true` | Install CustomResourceDefinitions |
6465
| examples.enabled | bool | `false` | Enable example resources to seed on first start |
6566
| fullnameOverride | string | `""` | Override the full release name |
6667
| gatewayApi.enabled | bool | `false` | Enable Gateway API resources |

deploy/charts/backend/crds/kube-bind.io_apiservicebindingbundles.yaml renamed to deploy/charts/backend/templates/crds/kube-bind.io_apiservicebindingbundles.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{{- if .Values.crds.install }}
12
---
23
apiVersion: apiextensions.k8s.io/v1
34
kind: CustomResourceDefinition
@@ -147,3 +148,4 @@ spec:
147148
storage: true
148149
subresources:
149150
status: {}
151+
{{- end }}

deploy/charts/backend/crds/kube-bind.io_apiservicebindings.yaml renamed to deploy/charts/backend/templates/crds/kube-bind.io_apiservicebindings.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{{- if .Values.crds.install }}
12
---
23
apiVersion: apiextensions.k8s.io/v1
34
kind: CustomResourceDefinition
@@ -461,3 +462,4 @@ spec:
461462
storage: true
462463
subresources:
463464
status: {}
465+
{{- end }}

deploy/charts/backend/crds/kube-bind.io_apiserviceexportrequests.yaml renamed to deploy/charts/backend/templates/crds/kube-bind.io_apiserviceexportrequests.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{{- if .Values.crds.install }}
12
---
23
apiVersion: apiextensions.k8s.io/v1
34
kind: CustomResourceDefinition
@@ -514,3 +515,4 @@ spec:
514515
storage: true
515516
subresources:
516517
status: {}
518+
{{- end }}

deploy/charts/backend/crds/kube-bind.io_apiserviceexports.yaml renamed to deploy/charts/backend/templates/crds/kube-bind.io_apiserviceexports.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{{- if .Values.crds.install }}
12
---
23
apiVersion: apiextensions.k8s.io/v1
34
kind: CustomResourceDefinition
@@ -750,3 +751,4 @@ spec:
750751
storage: true
751752
subresources:
752753
status: {}
754+
{{- end }}

deploy/charts/backend/crds/kube-bind.io_apiserviceexporttemplates.yaml renamed to deploy/charts/backend/templates/crds/kube-bind.io_apiserviceexporttemplates.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{{- if .Values.crds.install }}
12
---
23
apiVersion: apiextensions.k8s.io/v1
34
kind: CustomResourceDefinition
@@ -335,3 +336,4 @@ spec:
335336
storage: true
336337
subresources:
337338
status: {}
339+
{{- end }}

deploy/charts/backend/crds/kube-bind.io_apiservicenamespaces.yaml renamed to deploy/charts/backend/templates/crds/kube-bind.io_apiservicenamespaces.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{{- if .Values.crds.install }}
12
---
23
apiVersion: apiextensions.k8s.io/v1
34
kind: CustomResourceDefinition
@@ -122,3 +123,4 @@ spec:
122123
storage: true
123124
subresources:
124125
status: {}
126+
{{- end }}

deploy/charts/backend/crds/kube-bind.io_bindableresourcesrequests.yaml renamed to deploy/charts/backend/templates/crds/kube-bind.io_bindableresourcesrequests.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{{- if .Values.crds.install }}
12
---
23
apiVersion: apiextensions.k8s.io/v1
34
kind: CustomResourceDefinition
@@ -222,3 +223,4 @@ spec:
222223
storage: true
223224
subresources:
224225
status: {}
226+
{{- end }}

deploy/charts/backend/crds/kube-bind.io_boundschemas.yaml renamed to deploy/charts/backend/templates/crds/kube-bind.io_boundschemas.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{{- if .Values.crds.install }}
12
---
23
apiVersion: apiextensions.k8s.io/v1
34
kind: CustomResourceDefinition
@@ -466,3 +467,4 @@ spec:
466467
storage: true
467468
subresources:
468469
status: {}
470+
{{- end }}

deploy/charts/backend/crds/kube-bind.io_clusterbindings.yaml renamed to deploy/charts/backend/templates/crds/kube-bind.io_clusterbindings.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{{- if .Values.crds.install }}
12
---
23
apiVersion: apiextensions.k8s.io/v1
34
kind: CustomResourceDefinition
@@ -343,3 +344,4 @@ spec:
343344
storage: true
344345
subresources:
345346
status: {}
347+
{{- end }}

0 commit comments

Comments
 (0)