Add env to nextclouds

This commit is contained in:
M. Rehan
2022-09-05 21:20:52 +05:00
parent b396023fa5
commit 9139bb16a3
56 changed files with 47 additions and 4 deletions

View File

@@ -19,4 +19,4 @@ sources:
- https://github.com/nextcloud/docker
- https://github.com/nextcloud/helm
upstream_version: 2.3.2
version: 1.6.8
version: 1.6.9

View File

@@ -327,3 +327,24 @@ questions:
show_if: [["enableResourceLimits", "=", true]]
valid_chars: "^([+-]?[0-9.]+)([eEinumkKMGTP]*[-+]?[0-9]*)$"
default: "8Gi"
- variable: environmentVariables
label: "Nextcloud environment"
group: "Nextcloud Configuration"
schema:
type: list
default: []
items:
- variable: environmentVariable
label: "Environment Variable"
schema:
type: dict
attrs:
- variable: name
label: "Name"
schema:
type: string
- variable: value
label: "Value"
schema:
type: string

View File

@@ -31,8 +31,8 @@ spec: {{ include "common.deployment.common_spec" . | nindent 2 }}
{{ include "common.resources.limitation" . | nindent 8 }}
{{ include "common.containers.imageConfig" .Values.image | nindent 8 }}
env: {{ include "postgres.envVariableConfiguration" $postgres_values | nindent 10 }}
{{ $envList := list }}
{{ $secretName := (include "common.names.fullname" .) }}
{{ $envList := (default list .Values.environmentVariables) }}
{{ $envList = mustAppend $envList (dict "name" "POSTGRES_HOST" "value" (printf "%s:5432" (include "common.names.fullname" $postgres_values))) }}
{{ $envList = mustAppend $envList (dict "name" "POSTGRES_DB" "value" (include "postgres.DatabaseName" .)) }}
{{ $envList = mustAppend $envList (dict "name" "NEXTCLOUD_DATA_DIR" "value" .Values.nextcloud.datadir) }}

View File

@@ -42,3 +42,4 @@ service:
nodePort: 31000
updateStrategy: Recreate
useServiceNameForHost: true

View File

@@ -19,4 +19,4 @@ sources:
- https://github.com/nextcloud/docker
- https://github.com/nextcloud/helm
upstream_version: 2.3.2
version: 1.6.8
version: 1.6.9

View File

@@ -327,3 +327,24 @@ questions:
show_if: [["enableResourceLimits", "=", true]]
valid_chars: "^([+-]?[0-9.]+)([eEinumkKMGTP]*[-+]?[0-9]*)$"
default: "8Gi"
- variable: environmentVariables
label: "Nextcloud environment"
group: "Nextcloud Configuration"
schema:
type: list
default: []
items:
- variable: environmentVariable
label: "Environment Variable"
schema:
type: dict
attrs:
- variable: name
label: "Name"
schema:
type: string
- variable: value
label: "Value"
schema:
type: string

View File

@@ -31,8 +31,8 @@ spec: {{ include "common.deployment.common_spec" . | nindent 2 }}
{{ include "common.resources.limitation" . | nindent 8 }}
{{ include "common.containers.imageConfig" .Values.image | nindent 8 }}
env: {{ include "postgres.envVariableConfiguration" $postgres_values | nindent 10 }}
{{ $envList := list }}
{{ $secretName := (include "common.names.fullname" .) }}
{{ $envList := (default list .Values.environmentVariables) }}
{{ $envList = mustAppend $envList (dict "name" "POSTGRES_HOST" "value" (printf "%s:5432" (include "common.names.fullname" $postgres_values))) }}
{{ $envList = mustAppend $envList (dict "name" "POSTGRES_DB" "value" (include "postgres.DatabaseName" .)) }}
{{ $envList = mustAppend $envList (dict "name" "NEXTCLOUD_DATA_DIR" "value" .Values.nextcloud.datadir) }}