fix(mycloud-nextcloud): use official helm-chart
This commit is contained in:
parent
fabb9118c6
commit
e1cdb09953
3 changed files with 44 additions and 57 deletions
|
@ -7,9 +7,9 @@ spec:
|
||||||
chart:
|
chart:
|
||||||
spec:
|
spec:
|
||||||
sourceRef:
|
sourceRef:
|
||||||
kind: GitRepository
|
kind: HelmRepository
|
||||||
name: "nextcloud"
|
name: "nextcloud"
|
||||||
chart: "./charts/nextcloud"
|
chart: "nextcloud"
|
||||||
# TODO delete later
|
# TODO delete later
|
||||||
# https://codeberg.org/wrenix/flux-charts/issues/6
|
# https://codeberg.org/wrenix/flux-charts/issues/6
|
||||||
reconcileStrategy: "Revision"
|
reconcileStrategy: "Revision"
|
||||||
|
@ -100,17 +100,14 @@ spec:
|
||||||
# https://codeberg.org/wrenix/flux-charts/issues/7
|
# https://codeberg.org/wrenix/flux-charts/issues/7
|
||||||
before-starting: |-
|
before-starting: |-
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
echo "update all apps:";
|
{{- $app := "user_oidc" }}
|
||||||
/var/www/html/occ app:update --all;
|
echo "=== manage: {{ $app }} ==="
|
||||||
|
echo "--- install: {{ $app }} ---"
|
||||||
echo "setup theming:";
|
/var/www/html/occ app:install {{ $app }};
|
||||||
/var/www/html/occ theming:config disable-user-theming yes;
|
/var/www/html/occ app:enable {{ $app }};
|
||||||
/var/www/html/occ theming:config name "{{ .Values.commons.theme.title }}";
|
echo "--- configure: {{ $app }} ---"
|
||||||
{{- with .Values.theme.color }}
|
/var/www/html/occ config:app:set -n {{ $app }} allow_multiple_user_backends --value="0"
|
||||||
/var/www/html/occ theming:config color {{ . | quote }};
|
/var/www/html/occ config:app:set -n {{ $app }} provider-1-groupProvisioning --value="1"
|
||||||
{{- end }}
|
|
||||||
|
|
||||||
echo "setup oidc:";
|
|
||||||
/var/www/html/occ user_oidc:provider mycloud \
|
/var/www/html/occ user_oidc:provider mycloud \
|
||||||
--clientid $NC_HOOK_OIDC_CLIENT_ID \
|
--clientid $NC_HOOK_OIDC_CLIENT_ID \
|
||||||
--clientsecret $NC_HOOK_OIDC_CLIENT_SECRET \
|
--clientsecret $NC_HOOK_OIDC_CLIENT_SECRET \
|
||||||
|
@ -125,36 +122,37 @@ spec:
|
||||||
--check-bearer=true \
|
--check-bearer=true \
|
||||||
--unique-uid=0;
|
--unique-uid=0;
|
||||||
|
|
||||||
appManagement:
|
|
||||||
enabled: true
|
{{- range $app,$appConfig := .Values.apps }}
|
||||||
apps:
|
echo "=== manage app: {{ $app }} ===";
|
||||||
user_oidc:
|
{{- if $appConfig.enabled }}
|
||||||
enabled: true
|
echo "--- install: {{ $app }} ---"
|
||||||
config:
|
/var/www/html/occ app:install {{ $app }}
|
||||||
allow_multiple_user_backends: "0"
|
/var/www/html/occ app:enable {{ $app }}
|
||||||
provider-1-groupProvisioning: "1"
|
# config of app
|
||||||
##
|
echo "--- config: {{ $app }} ---"
|
||||||
# collabora
|
{{- range $key, $value := $appConfig.config }}
|
||||||
##
|
/var/www/html/occ config:app:set -n {{ $app }} {{ $key }} --value={{ $value | quote }}
|
||||||
{{- with .Values.apps.richdocuments }}
|
{{- end}}
|
||||||
{{- if .enabled }}
|
|
||||||
richdocuments:
|
|
||||||
enabled: true
|
|
||||||
{{- with .config }}
|
|
||||||
config:
|
|
||||||
{{- with (get . "wopi_url") }}
|
|
||||||
wopi_url: {{ . }}
|
|
||||||
{{- else }}
|
{{- else }}
|
||||||
wopi_url: "https://collabora.{{ $.Values.commons.ingress.domain }}"
|
echo "--- disable: {{ $app }} ---"
|
||||||
|
/var/www/html/occ app:disable {{ $app }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- with (omit . "wopi_url") }}
|
{{- end }}{{/* end-range */}}
|
||||||
{{- toYaml . | nindent 14 }}
|
|
||||||
{{- end }}
|
{{- if .Values.apps.richdocuments.enabled }}
|
||||||
{{- end }}{{/* with .config */}}
|
echo "=== manage: richdocuments -> configure for mycloud-collabora ==="
|
||||||
{{- end }}{{/* end-if .enabled */}}
|
/var/www/html/occ config:app:set -n richdocuments wopi_url --value={{ get .Values.apps.richdocuments.config "wopi_url" | default (printf "https://collabora.%s" $.Values.commons.ingress.domain) | quote }}
|
||||||
{{- end }}{{/* end-with .richdocuments */}}
|
{{- end }}{{/* end-else-if richdocuments.enable */}}
|
||||||
{{- with (omit .Values.apps "richdocuments") }}
|
|
||||||
{{- toYaml . | nindent 10 }}
|
echo "update all apps:";
|
||||||
|
/var/www/html/occ app:update --all;
|
||||||
|
|
||||||
|
echo "setup theming:";
|
||||||
|
/var/www/html/occ theming:config disable-user-theming yes;
|
||||||
|
/var/www/html/occ theming:config name "{{ .Values.commons.theme.title }}";
|
||||||
|
{{- with .Values.theme.color }}
|
||||||
|
/var/www/html/occ theming:config color {{ . | quote }};
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
||||||
phpClientHttpsFix:
|
phpClientHttpsFix:
|
||||||
|
|
|
@ -1,14 +1,8 @@
|
||||||
---
|
---
|
||||||
apiVersion: source.toolkit.fluxcd.io/v1
|
apiVersion: source.toolkit.fluxcd.io/v1beta2
|
||||||
kind: GitRepository
|
kind: HelmRepository
|
||||||
metadata:
|
metadata:
|
||||||
name: nextcloud
|
name: nextcloud
|
||||||
spec:
|
spec:
|
||||||
url: https://github.com/wrenix/nextcloud-helm.git
|
url: https://nextcloud.github.io/helm/
|
||||||
ref:
|
|
||||||
{{- with .Values.helm.nextcloud.chart }}
|
|
||||||
commit: {{ . }}
|
|
||||||
{{- else }}
|
|
||||||
branch: main
|
|
||||||
{{- end }}
|
|
||||||
interval: 10m
|
interval: 10m
|
||||||
|
|
|
@ -54,11 +54,6 @@ commons:
|
||||||
redis:
|
redis:
|
||||||
replicas: 0
|
replicas: 0
|
||||||
|
|
||||||
helm:
|
|
||||||
nextcloud:
|
|
||||||
# -- version of the helm chart (current on git)
|
|
||||||
chart: "616d6ef694c862733932040293ba0cef8b1e7335"
|
|
||||||
|
|
||||||
# -- generated by .Values.commons.masterPassword
|
# -- generated by .Values.commons.masterPassword
|
||||||
adminPassword:
|
adminPassword:
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue