我无法获取基本图表版本, 似乎需要解决方法,
在模板中尝试定义 尝试在_helpers.tpl
中定义{{- define "bitcore.deployment" -}}
{{- $common := dict "Values" .Values.bitcore -}}
{{- $noCommon := omit .Values "bitcore" -}}
{{- $overrides := dict "Values" $noCommon -}}
{{- $noValues := omit . "Values" -}}
{{- with merge $noValues $overrides $common -}}
apiVersion: apps.openshift.io/v1
kind: DeploymentConfig
metadata:
annotations:
openshift.io/generated-by: OpenShiftNewApp
labels:
app: {{ .Chart.Name }}
name: {{ .Chart.Name }}
spec:
replicas: {{ .Values.replicaCount }}
selector:
app: {{ .Chart.Name }}
deploymentconfig: {{ .Chart.Name }}
strategy:
activeDeadlineSeconds: 21600
recreateParams:
timeoutSeconds: 600
resources: {}
type: Recreate
template:
metadata:
annotations:
openshift.io/generated-by: OpenShiftNewApp
labels:
app: {{ .Chart.Name }}
deploymentconfig: {{ .Chart.Name }}
test: required
spec:
containers:
- image: "{{ .Values.image.repository }}:{{ $.Chart.Version }}"
imagePullPolicy: {{ .Values.global.image.pullPolicy }}
env:
- name: BIT_CORE_RUNTIME_PROFILE
value: '{{ required "Please provide runtime profile" .Values.global.runtimeProfile }}'
- name: JAVA_OPTS
value: '{{ required "Please provide Java Ops." .Values.global.javaOpts }}'
{{- end -}}
{{- end -}}
期望从基本图表中获取真实版本 非常感谢!!!!