diff --git a/charts/nginx-gateway-fabric/README.md b/charts/nginx-gateway-fabric/README.md index 531386c0c7..b8c6a35b3e 100644 --- a/charts/nginx-gateway-fabric/README.md +++ b/charts/nginx-gateway-fabric/README.md @@ -307,6 +307,7 @@ The following table lists the configurable parameters of the NGINX Gateway Fabri | `serviceAccount.name` | The name of the service account of the NGINX Gateway Fabric pods. Used for RBAC. | string | Autogenerated if not set or set to "" | | `terminationGracePeriodSeconds` | The termination grace period of the NGINX Gateway Fabric pod. | int | `30` | | `tolerations` | Tolerations for the NGINX Gateway Fabric pod. | list | `[]` | +| `topologySpreadConstraints` | The topology spread constraints for the NGINX Gateway Fabric pod. | list | `[]` | ---------------------------------------------- Autogenerated from chart metadata using [helm-docs](https://github.com/norwoodj/helm-docs) diff --git a/charts/nginx-gateway-fabric/templates/deployment.yaml b/charts/nginx-gateway-fabric/templates/deployment.yaml index f669ded5c2..d1bd9e8b05 100644 --- a/charts/nginx-gateway-fabric/templates/deployment.yaml +++ b/charts/nginx-gateway-fabric/templates/deployment.yaml @@ -29,6 +29,10 @@ spec: {{- end }} {{- end }} spec: + {{- if .Values.topologySpreadConstraints }} + topologySpreadConstraints: + {{- toYaml .Values.topologySpreadConstraints | nindent 8 }} + {{- end }} initContainers: - name: copy-nginx-config image: {{ .Values.nginxGateway.image.repository }}:{{ default .Chart.AppVersion .Values.nginxGateway.image.tag }} diff --git a/charts/nginx-gateway-fabric/values.schema.json b/charts/nginx-gateway-fabric/values.schema.json index 94211e9322..38cbbd34d2 100644 --- a/charts/nginx-gateway-fabric/values.schema.json +++ b/charts/nginx-gateway-fabric/values.schema.json @@ -676,6 +676,15 @@ "required": [], "title": "tolerations", "type": "array" + }, + "topologySpreadConstraints": { + "description": "The topology spread constraints for the NGINX Gateway Fabric pod.", + "items": { + "required": [] + }, + "required": [], + "title": "topologySpreadConstraints", + "type": "array" } }, "required": [], diff --git a/charts/nginx-gateway-fabric/values.yaml b/charts/nginx-gateway-fabric/values.yaml index 652acedbdc..3200a4eae9 100644 --- a/charts/nginx-gateway-fabric/values.yaml +++ b/charts/nginx-gateway-fabric/values.yaml @@ -260,6 +260,9 @@ nodeSelector: {} # -- The affinity of the NGINX Gateway Fabric pod. affinity: {} +# -- The topology spread constraints for the NGINX Gateway Fabric pod. +topologySpreadConstraints: [] + serviceAccount: # -- Set of custom annotations for the NGINX Gateway Fabric service account. annotations: {}