feat(helm): Optimize Helm charts, fine-tune the imagePullPolicy configuration for gateway, plugin server, and controller pods (#3550)

This commit is contained in:
icylord
2026-04-08 21:47:48 +08:00
committed by GitHub
parent 60ce07d297
commit 69523292cb
5 changed files with 26 additions and 2 deletions

View File

@@ -20,6 +20,11 @@ template:
{{- end }} {{- end }}
{{- include "gateway.selectorLabels" . | nindent 6 }} {{- include "gateway.selectorLabels" . | nindent 6 }}
spec: spec:
{{- if .Values.gateway.imagePullPolicy }}
imagePullPolicy: {{ .Values.gateway.imagePullPolicy }}
{{- else if .Values.global.imagePullPolicy }}
imagePullPolicy: {{ .Values.global.imagePullPolicy }}
{{- end }}
{{- with .Values.gateway.imagePullSecrets }} {{- with .Values.gateway.imagePullSecrets }}
imagePullSecrets: imagePullSecrets:
{{- toYaml . | nindent 6 }} {{- toYaml . | nindent 6 }}

View File

@@ -105,7 +105,9 @@ spec:
mountPath: /var/log mountPath: /var/log
- name: discovery - name: discovery
image: "{{ .Values.pilot.hub | default .Values.global.hub }}/higress/{{ .Values.pilot.image | default "pilot" }}:{{ .Values.pilot.tag | default .Chart.AppVersion }}" image: "{{ .Values.pilot.hub | default .Values.global.hub }}/higress/{{ .Values.pilot.image | default "pilot" }}:{{ .Values.pilot.tag | default .Chart.AppVersion }}"
{{- if .Values.global.imagePullPolicy }} {{- if .Values.controller.imagePullPolicy }}
imagePullPolicy: {{ .Values.controller.imagePullPolicy }}
{{- else if .Values.global.imagePullPolicy }}
imagePullPolicy: {{ .Values.global.imagePullPolicy }} imagePullPolicy: {{ .Values.global.imagePullPolicy }}
{{- end }} {{- end }}
args: args:

View File

@@ -24,7 +24,9 @@ spec:
containers: containers:
- name: {{ .Chart.Name }} - name: {{ .Chart.Name }}
image: {{ .Values.pluginServer.hub | default .Values.global.hub }}/higress/{{ .Values.pluginServer.image | default "plugin-server" }}:{{ .Values.pluginServer.tag | default "1.0.0" }} image: {{ .Values.pluginServer.hub | default .Values.global.hub }}/higress/{{ .Values.pluginServer.image | default "plugin-server" }}:{{ .Values.pluginServer.tag | default "1.0.0" }}
{{- if .Values.global.imagePullPolicy }} {{- if .Values.pluginServer.imagePullPolicy }}
imagePullPolicy: {{ .Values.pluginServer.imagePullPolicy }}
{{- else if .Values.global.imagePullPolicy }}
imagePullPolicy: {{ .Values.global.imagePullPolicy }} imagePullPolicy: {{ .Values.global.imagePullPolicy }}
{{- end }} {{- end }}
ports: ports:

View File

@@ -423,6 +423,10 @@ gateway:
replicas: 2 replicas: 2
image: gateway image: gateway
# -- Specify image pull policy if default behavior isn't desired.
# Default behavior: latest images will be Always else IfNotPresent.
imagePullPolicy: ""
# -- Use a `DaemonSet` or `Deployment` # -- Use a `DaemonSet` or `Deployment`
kind: Deployment kind: Deployment
@@ -577,6 +581,10 @@ controller:
periodSeconds: 3 periodSeconds: 3
timeoutSeconds: 5 timeoutSeconds: 5
# -- Specify image pull policy if default behavior isn't desired.
# Default behavior: latest images will be Always else IfNotPresent.
imagePullPolicy: ""
imagePullSecrets: [] imagePullSecrets: []
rbac: rbac:
@@ -786,6 +794,10 @@ pluginServer:
hub: "" # Will use global.hub if not set hub: "" # Will use global.hub if not set
tag: "" tag: ""
# -- Specify image pull policy if default behavior isn't desired.
# Default behavior: latest images will be Always else IfNotPresent.
imagePullPolicy: ""
imagePullSecrets: [] imagePullSecrets: []
labels: {} labels: {}

View File

@@ -46,6 +46,7 @@ The command removes all the Kubernetes components associated with the chart and
| controller.env | object | `{}` | | | controller.env | object | `{}` | |
| controller.hub | string | `""` | | | controller.hub | string | `""` | |
| controller.image | string | `"higress"` | | | controller.image | string | `"higress"` | |
| controller.imagePullPolicy | string | `""` | Specify image pull policy if default behavior isn't desired. Default behavior: latest images will be Always else IfNotPresent. |
| controller.imagePullSecrets | list | `[]` | | | controller.imagePullSecrets | list | `[]` | |
| controller.labels | object | `{}` | | | controller.labels | object | `{}` | |
| controller.name | string | `"higress-controller"` | | | controller.name | string | `"higress-controller"` | |
@@ -98,6 +99,7 @@ The command removes all the Kubernetes components associated with the chart and
| gateway.httpsPort | int | `443` | | | gateway.httpsPort | int | `443` | |
| gateway.hub | string | `""` | | | gateway.hub | string | `""` | |
| gateway.image | string | `"gateway"` | | | gateway.image | string | `"gateway"` | |
| gateway.imagePullPolicy | string | `""` | Specify image pull policy if default behavior isn't desired. Default behavior: latest images will be Always else IfNotPresent. |
| gateway.kind | string | `"Deployment"` | Use a `DaemonSet` or `Deployment` | | gateway.kind | string | `"Deployment"` | Use a `DaemonSet` or `Deployment` |
| gateway.labels | object | `{}` | Labels to apply to all resources | | gateway.labels | object | `{}` | Labels to apply to all resources |
| gateway.metrics.enabled | bool | `false` | If true, create PodMonitor or VMPodScrape for gateway | | gateway.metrics.enabled | bool | `false` | If true, create PodMonitor or VMPodScrape for gateway |
@@ -270,6 +272,7 @@ The command removes all the Kubernetes components associated with the chart and
| pilot.traceSampling | float | `1` | | | pilot.traceSampling | float | `1` | |
| pluginServer.hub | string | `""` | | | pluginServer.hub | string | `""` | |
| pluginServer.image | string | `"plugin-server"` | | | pluginServer.image | string | `"plugin-server"` | |
| pluginServer.imagePullPolicy | string | `""` | Specify image pull policy if default behavior isn't desired. Default behavior: latest images will be Always else IfNotPresent. |
| pluginServer.imagePullSecrets | list | `[]` | | | pluginServer.imagePullSecrets | list | `[]` | |
| pluginServer.labels | object | `{}` | | | pluginServer.labels | object | `{}` | |
| pluginServer.name | string | `"higress-plugin-server"` | | | pluginServer.name | string | `"higress-plugin-server"` | |