Skip to content

Commit 58b818f

Browse files
committed
fix(opencloud): add option to set env and envFrom (use services from values)
1 parent 4a3cdc1 commit 58b818f

File tree

3 files changed

+20
-7
lines changed

3 files changed

+20
-7
lines changed

Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ maintainers:
1010
1111
url: https://opencloud.eu
1212
type: application
13-
version: 0.1.1
13+
version: 0.1.2
1414
# renovate: datasource=docker depName=opencloudeu/opencloud-rolling
1515
appVersion: latest
1616
kubeVersion: ""

templates/opencloud/deployment.yaml

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,10 @@ spec:
119119
imagePullPolicy: {{ .Values.image.pullPolicy }}
120120
command: ["/bin/sh"]
121121
args: ["-c", "opencloud init || true; opencloud server"]
122+
{{- with .Values.opencloud.envFrom }}
123+
envFrom:
124+
{{- toYaml . | nindent 12 }}
125+
{{- end }}
122126
env:
123127
# OpenCloud URL
124128
- name: OC_URL
@@ -134,11 +138,14 @@ spec:
134138
- name: OC_LOG_PRETTY
135139
value: {{ .Values.opencloud.logPretty | quote }}
136140
# Enable services that are not started automatically
141+
{{- with .Values.opencloud.additionalServices }}
137142
- name: OC_ADD_RUN_SERVICES
138-
value: {{ .Values.opencloud.additionalServices | quote }}
139-
# Only exclude idp
143+
value: {{ join "," . | quote }}
144+
{{- end }}
145+
{{- with .Values.opencloud.excludeServices }}
140146
- name: OC_EXCLUDE_RUN_SERVICES
141-
value: "idp"
147+
value: {{ join "," . | quote }}
148+
{{- end }}
142149
# Do not use SSL between proxy and OpenCloud
143150
- name: PROXY_TLS
144151
value: "false"
@@ -256,6 +263,9 @@ spec:
256263
value: {{ if .Values.opencloud.storage.s3.external.enabled }}{{ .Values.opencloud.storage.s3.external.bucket | quote }}{{ else }}{{ .Values.opencloud.storage.s3.internal.bucketName | quote }}{{ end }}
257264
- name: STORAGE_USERS_DECOMPOSEDS3_CREATE_BUCKET
258265
value: {{ if .Values.opencloud.storage.s3.external.enabled }}{{ .Values.opencloud.storage.s3.external.createBucket | default true | quote }}{{ else }}"true"{{ end }}
266+
{{- with .Values.opencloud.env }}
267+
{{- toYaml . | nindent 12 }}
268+
{{- end }}
259269
ports:
260270
- name: http
261271
containerPort: 9200

values.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -381,10 +381,13 @@ opencloud:
381381
adminPassword: admin
382382
# Create demo users
383383
createDemoUsers: false
384-
# Additional services to start (comma-separated list)
385-
additionalServices: ""
384+
# Additional services to start
385+
additionalServices: []
386386
# Services to exclude from starting
387-
excludeServices: "idp"
387+
excludeServices:
388+
- "idp"
389+
env: []
390+
envFrom: []
388391
# Resources allocation
389392
resources:
390393
requests:

0 commit comments

Comments
 (0)