mirror of
https://github.com/truenas/charts.git
synced 2026-11-04 06:35:02 +08:00
Remove storage tpl functions from plex chart
This commit is contained in:
@@ -50,32 +50,3 @@ Selector labels
|
||||
app.kubernetes.io/name: {{ include "plex.name" . }}
|
||||
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Create the name of the service account to use
|
||||
*/}}
|
||||
{{- define "plex.serviceAccountName" -}}
|
||||
{{- if .Values.serviceAccount.create -}}
|
||||
{{ default (include "plex.fullname" .) .Values.serviceAccount.name }}
|
||||
{{- else -}}
|
||||
{{ default "default" .Values.serviceAccount.name }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
abstract: |
|
||||
Joins a list of values into a comma separated string
|
||||
values: |
|
||||
test:
|
||||
- foo
|
||||
- bar
|
||||
usage: |
|
||||
{{ include "joinListWithComma" .Values.test }}
|
||||
return: |
|
||||
foo,bar
|
||||
*/}}
|
||||
|
||||
{{- define "joinListWithComma" -}}
|
||||
{{- $local := dict "first" true -}}
|
||||
{{- range $k, $v := . -}}{{- if not $local.first -}},{{- end -}}{{- $v -}}{{- $_ := set $local "first" false -}}{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -1,50 +0,0 @@
|
||||
{{/*
|
||||
Retrieve host path from ix volumes based on dataset name
|
||||
*/}}
|
||||
{{- define "retrieveHostPathFromiXVolume" -}}
|
||||
{{- range $index, $hostPathConfiguration := $.ixVolumes }}
|
||||
{{- $dsName := base $hostPathConfiguration.hostPath -}}
|
||||
{{- if eq $.datasetName $dsName -}}
|
||||
{{- $hostPathConfiguration.hostPath -}}
|
||||
{{- end -}}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Retrieve host path for transcode
|
||||
Let's please remove the redundancy
|
||||
*/}}
|
||||
{{- define "configuredHostPathTranscode" -}}
|
||||
{{- if .Values.transcodeHostPathEnabled -}}
|
||||
{{- .Values.transcodeHostPath -}}
|
||||
{{- else -}}
|
||||
{{- $volDict := dict "datasetName" $.Values.transcodeVolume.datasetName "ixVolumes" $.Values.ixVolumes -}}
|
||||
{{- include "retrieveHostPathFromiXVolume" $volDict -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Retrieve host path for data
|
||||
Let's please remove the redundancy
|
||||
*/}}
|
||||
{{- define "configuredHostPathData" -}}
|
||||
{{- if .Values.dataHostPathEnabled -}}
|
||||
{{- .Values.dataHostPath -}}
|
||||
{{- else -}}
|
||||
{{- $volDict := dict "datasetName" $.Values.dataVolume.datasetName "ixVolumes" $.Values.ixVolumes -}}
|
||||
{{- include "retrieveHostPathFromiXVolume" $volDict -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Retrieve host path for transcode
|
||||
Let's please remove the redundancy
|
||||
*/}}
|
||||
{{- define "configuredHostPathConfig" -}}
|
||||
{{- if .Values.configHostPathEnabled -}}
|
||||
{{- .Values.configHostPath -}}
|
||||
{{- else -}}
|
||||
{{- $volDict := dict "datasetName" $.Values.configVolume.datasetName "ixVolumes" $.Values.ixVolumes -}}
|
||||
{{- include "retrieveHostPathFromiXVolume" $volDict -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
Reference in New Issue
Block a user