diff --git a/templates/auth.yaml b/templates/auth.yaml index 0762c5f..488968c 100644 --- a/templates/auth.yaml +++ b/templates/auth.yaml @@ -1,4 +1,16 @@ --- +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + name: ldap-pvc +spec: + accessModes: + - ReadWriteMany + resources: + requests: + storage: 100Mi + storageClassName: longhorn +--- {{- define "homey.auth.ingress.annotations" }} # nginx.ingress.kubernetes.io/auth-signin: "https://auth.zakobar.com" nginx.ingress.kubernetes.io/auth-url: "http://ldap-auth-internal.{{ .Release.Namespace }}.svc.cluster.local:80" @@ -89,7 +101,7 @@ spec: volumes: - name: openldap-volume persistentVolumeClaim: - claimName: homey-pvc-nfs + claimName: ldap-pvc --- apiVersion: v1 kind: Service @@ -159,7 +171,7 @@ spec: # volumes: # - name: keycloak-postgresdb # persistentVolumeClaim: -# claimName: homey-pvc-nfs +# claimName: homey-pvc-longhorn # --- # apiVersion: v1 # kind: Service @@ -268,3 +280,4 @@ spec: # name: keycloak-web # port: # number: 8080 +--- diff --git a/templates/gitea.yaml b/templates/gitea.yaml index b8c8768..ad26392 100644 --- a/templates/gitea.yaml +++ b/templates/gitea.yaml @@ -1,5 +1,17 @@ --- apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + name: gitea-pvc +spec: + accessModes: + - ReadWriteMany + resources: + requests: + storage: 5Gi + storageClassName: longhorn +--- +apiVersion: v1 kind: Secret metadata: name: gitea-admin-pass @@ -39,7 +51,7 @@ spec: volumes: - name: gitea-persistent-storage persistentVolumeClaim: - claimName: homey-pvc-nfs + claimName: gitea-pvc --- apiVersion: v1 kind: Service @@ -77,3 +89,4 @@ spec: name: gitea-svc port: number: 3000 +--- diff --git a/templates/nextcloud.yaml b/templates/nextcloud.yaml index dd213ee..60dd593 100644 --- a/templates/nextcloud.yaml +++ b/templates/nextcloud.yaml @@ -1,5 +1,41 @@ --- apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + name: nextcloud-pvc +spec: + accessModes: + - ReadWriteMany + resources: + requests: + storage: 30Gi + storageClassName: longhorn +--- +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + name: nextcloud-postgres-pvc +spec: + accessModes: + - ReadWriteMany + resources: + requests: + storage: 5Gi + storageClassName: longhorn +--- +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + name: nextcloud-data-pvc +spec: + accessModes: + - ReadWriteMany + resources: + requests: + storage: 30Gi + storageClassName: longhorn +--- +apiVersion: v1 kind: Secret metadata: name: nextcloud-postgres-pass @@ -62,7 +98,7 @@ spec: volumes: - name: nextcloud-postgredb persistentVolumeClaim: - claimName: homey-pvc-nfs + claimName: nextcloud-postgres-pvc --- apiVersion: v1 kind: Service @@ -101,6 +137,9 @@ spec: - name: nextcloud-volume mountPath: "/var/www/html" subPath: nextcloud/html + - name: nextcloud-media + mountPath: "/var/www/html/data" + subPath: nextcloud/html/data envFrom: - configMapRef: name: nextcloud-postgres-config @@ -117,7 +156,10 @@ spec: volumes: - name: nextcloud-volume persistentVolumeClaim: - claimName: homey-pvc-nfs + claimName: nextcloud-pvc + - name: nextcloud-media + persistentVolumeClaim: + claimName: nextcloud-data-pvc --- apiVersion: v1 kind: Service @@ -136,6 +178,7 @@ kind: Ingress metadata: name: nextcloud-ingress annotations: + nginx.ingress.kubernetes.io/proxy-body-size: 5g nginx.ingress.kubernetes.io/server-snippet: | # Make a regex exception for `/.well-known` so that clients can still # access it despite the existence of the regex rule @@ -160,3 +203,4 @@ spec: name: nextcloud port: number: 80 +--- diff --git a/templates/phpldapadmin.yaml b/templates/phpldapadmin.yaml index 31e5309..ae0c22e 100644 --- a/templates/phpldapadmin.yaml +++ b/templates/phpldapadmin.yaml @@ -43,8 +43,6 @@ apiVersion: networking.k8s.io/v1 kind: Ingress metadata: name: phpldapadmin - annotations: - {{ template "homey.auth.ingress.annotations" $ }} spec: ingressClassName: {{ .Values.homey.ingress_class }} tls: diff --git a/templates/storage.yaml b/templates/storage.yaml deleted file mode 100644 index a8b4200..0000000 --- a/templates/storage.yaml +++ /dev/null @@ -1,30 +0,0 @@ ---- -apiVersion: v1 -kind: PersistentVolume -metadata: - name: homey-pv-nfs - labels: - isbackup: "true" -spec: - capacity: - storage: {{ .Values.homey.storage.storageCapacity }} - storageClassName: standard - accessModes: - - ReadWriteMany - persistentVolumeReclaimPolicy: Recycle - nfs: - path: / - server: {{ .Values.homey.storage.ip }} - readOnly: false ---- -apiVersion: v1 -kind: PersistentVolumeClaim -metadata: - name: homey-pvc-nfs -spec: - accessModes: - - ReadWriteMany - resources: - requests: - storage: {{ .Values.homey.storage.storageCapacity }} - storageClassName: standard diff --git a/values.yaml b/values.yaml index 8a20405..863552b 100644 --- a/values.yaml +++ b/values.yaml @@ -61,6 +61,7 @@ homey: storage: ip: "10.0.0.100" storageCapacity: 30Gi + mediaStorageCapacity: 30Gi url: zakobar.com ip: 10.0.0.100 certname: zakobarcert