Commit 06a75d2c authored by Waqar Ahmed's avatar Waqar Ahmed

Add check for env variable at chart level instead of schema

This commit introduces a change by marking env variable name/value variables as not required as UI cannot properly handle this right now.
parent 51d5e889
......@@ -83,12 +83,10 @@ questions:
label: "Name"
schema:
type: string
required: true
- variable: value
label: "Value"
schema:
type: string
required: true
- variable: service
description: "IPFS Service Configuration"
......
......@@ -106,8 +106,12 @@ spec:
{{- if .Values.environment }}
env:
{{- range $envVariable := .Values.environment }}
{{- if and $envVariable.name $envVariable.value }}
- name: {{ $envVariable.name }}
value: {{ $envVariable.value | quote }}
{{- else }}
{{- fail "Please specify name/value for environment variable" }}
{{- end }}
{{- end}}
{{- end }}
volumes:
......
......@@ -116,12 +116,10 @@ questions:
label: "Name"
schema:
type: string
required: true
- variable: value
label: "Value"
schema:
type: string
required: true
- variable: service
description: "Minio Service Configuration"
......
......@@ -51,8 +51,12 @@ spec:
name: {{ template "minio.secretName" . }}
key: secretkey
{{- range $envVariable := .Values.environment }}
{{- if and $envVariable.name $envVariable.value }}
- name: {{ $envVariable.name }}
value: {{ $envVariable.value | quote }}
{{- else }}
{{- fail "Please specify name/value for environment variable" }}
{{- end }}
{{- end}}
volumes:
- name: export
......
......@@ -98,12 +98,10 @@ questions:
label: "Name"
schema:
type: string
required: true
- variable: value
label: "Value"
schema:
type: string
required: true
- variable: timezone
label: "Plex container timezone"
......
......@@ -69,8 +69,12 @@ spec:
fieldPath: metadata.namespace
# Extra ENV Values supplied by user
{{- range $envVariable := .Values.environmentVariables }}
{{- if and $envVariable.name $envVariable.value }}
- name: {{ $envVariable.name }}
value: {{ $envVariable.value | quote }}
{{- else }}
{{- fail "Please specify name/value for environment variable" }}
{{- end }}
{{- end}}
readinessProbe:
httpGet:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment