bugfix: 支持使用runtime单实例 (#118)

* bugfix: 支持使用runtime单实例
This commit is contained in:
hhhhsc701
2025-12-01 19:05:50 +08:00
committed by GitHub
parent bb3345268e
commit f730bd5b0c
15 changed files with 435 additions and 33 deletions

View File

@@ -246,3 +246,13 @@ false
{{- end -}}
{{- end -}}
{{- end -}}
{{- define "runtime.image" -}}
{{- $name := default .Values.image.repository .Values.global.image.runtime.name }}
{{- $tag := default .Values.image.tag .Values.global.image.runtime.tag }}
{{- if .Values.global.image.repository }}
{{- .Values.global.image.repository | trimSuffix "/" }}/{{ $name }}:{{ $tag }}
{{- else }}
{{- $name }}:{{ $tag }}
{{- end }}
{{- end }}

View File

@@ -49,7 +49,7 @@ spec:
- /bin/bash
- -c
- "cp -r /opt/heaptrack /milvus/tools"
image: "{{ .Values.heaptrack.image.repository }}:{{ .Values.heaptrack.image.tag }}"
image: "{{ .Values.global.imageRegistry | trimSuffix "/" }}/{{ .Values.heaptrack.image.repository }}:{{ .Values.heaptrack.image.tag }}"
imagePullPolicy: {{ .Values.heaptrack.image.pullPolicy }}
{{ if and (.Values.containerSecurityContext) (not .Values.standalone.containerSecurityContext) }}
securityContext:
@@ -65,7 +65,11 @@ spec:
{{- end }}
containers:
- name: standalone
{{- if .Values.global.imageRegistry }}
image: "{{ .Values.global.imageRegistry | trimSuffix "/" }}/{{ .Values.image.all.repository }}:{{ .Values.image.all.tag }}"
{{- else }}
image: "{{ .Values.image.all.repository }}:{{ .Values.image.all.tag }}"
{{- end }}
imagePullPolicy: {{ .Values.image.all.pullPolicy }}
{{ if and (.Values.containerSecurityContext) (not .Values.standalone.containerSecurityContext) }}
securityContext: