[kubernetes] refactor gatewayAPI option

Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
This commit is contained in:
Andrei Kvapil
2025-05-08 12:17:41 +02:00
parent 68c85ac9ef
commit 563c643813
10 changed files with 25 additions and 8 deletions

View File

@@ -22,4 +22,4 @@ version: 0.20.0
# incremented each time you make changes to the application. Versions are not expected to
# follow Semantic Versioning. They should reflect the version the application is using.
# It is recommended to use it with quotes.
appVersion: "1.30.1"
appVersion: 1.31.0

View File

@@ -45,6 +45,7 @@ kubectl get secret -n <namespace> kubernetes-<clusterName>-admin-kubeconfig -o g
| `addons.certManager.enabled` | Enables the cert-manager | `false` |
| `addons.certManager.valuesOverride` | Custom values to override | `{}` |
| `addons.cilium.valuesOverride` | Custom values to override | `{}` |
| `addons.gatewayAPI.enabled` | Enables the Gateway API | `false` |
| `addons.ingressNginx.enabled` | Enable Ingress-NGINX controller (expect nodes with 'ingress-nginx' role) | `false` |
| `addons.ingressNginx.valuesOverride` | Custom values to override | `{}` |
| `addons.ingressNginx.hosts` | List of domain names that should be passed through to the cluster by upper cluster | `[]` |

View File

@@ -53,6 +53,6 @@ spec:
namespace: {{ .Release.Namespace }}
{{- end }}
{{- if $.Values.addons.gatewayAPI.enabled }}
- name: {{ .Release.Name }}-gateway-api
- name: {{ .Release.Name }}-gateway-api-crds
namespace: {{ .Release.Namespace }}
{{- end }}

View File

@@ -30,6 +30,7 @@ spec:
patch
helmrelease
{{ .Release.Name }}-cilium
{{ .Release.Name }}-gateway-api-crds
{{ .Release.Name }}-csi
{{ .Release.Name }}-cert-manager
{{ .Release.Name }}-cert-manager-crds

View File

@@ -2,16 +2,16 @@
apiVersion: helm.toolkit.fluxcd.io/v2
kind: HelmRelease
metadata:
name: {{ .Release.Name }}-gateway-api
name: {{ .Release.Name }}-gateway-api-crds
labels:
cozystack.io/repository: system
cozystack.io/target-cluster-name: {{ .Release.Name }}
spec:
interval: 5m
releaseName: gateway-api
releaseName: gateway-api-crds
chart:
spec:
chart: cozy-gateway-api
chart: cozy-gateway-api-crds
reconcileStrategy: Revision
sourceRef:
kind: HelmRepository

View File

@@ -155,6 +155,16 @@
}
}
},
"gatewayAPI": {
"type": "object",
"properties": {
"enabled": {
"type": "boolean",
"description": "Enables the Gateway API",
"default": false
}
}
},
"ingressNginx": {
"type": "object",
"properties": {

View File

@@ -48,6 +48,12 @@ addons:
## @param addons.cilium.valuesOverride Custom values to override
valuesOverride: {}
## Gateway API
##
gatewayAPI:
## @param addons.gatewayAPI.enabled Enables the Gateway API
enabled: false
## Ingress-NGINX Controller
##
ingressNginx:

View File

@@ -1,3 +1,3 @@
apiVersion: v2
name: cozy-gateway-api
name: cozy-gateway-api-crds
version: 0.0.0 # Placeholder, the actual version will be automatically set during the build process

View File

@@ -1,4 +1,4 @@
export NAME=gateway-api
export NAME=gateway-api-crds
export NAMESPACE=cozy-$(NAME)
include ../../../scripts/package.mk
@@ -7,4 +7,3 @@ update:
rm -rf templates
mkdir templates
kubectl kustomize "github.com/kubernetes-sigs/gateway-api/config/crd/experimental?ref=v1.2.0" > templates/crds-experimental.yaml