ADD: added working nextcloud version
This commit is contained in:
33
k3s/apps/Nextcloud/manifest/collabora-deployment.yaml
Normal file
33
k3s/apps/Nextcloud/manifest/collabora-deployment.yaml
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: collabora
|
||||||
|
namespace: nextcloud
|
||||||
|
spec:
|
||||||
|
replicas: 1
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: collabora
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: collabora
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- name: collabora
|
||||||
|
image: collabora/code:latest
|
||||||
|
imagePullPolicy: Always
|
||||||
|
ports:
|
||||||
|
- containerPort: 9980
|
||||||
|
env:
|
||||||
|
- name: domain
|
||||||
|
value: "henryathome.home64.de"
|
||||||
|
- name: extra_params
|
||||||
|
value: "--o:ssl.enable=false --o:ssl.termination=true"
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
memory: "1Gi"
|
||||||
|
cpu: "500m"
|
||||||
|
limits:
|
||||||
|
memory: "4Gi"
|
||||||
|
cpu: "2"
|
||||||
13
k3s/apps/Nextcloud/manifest/collabora-service.yaml
Normal file
13
k3s/apps/Nextcloud/manifest/collabora-service.yaml
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: collabora-nodeport
|
||||||
|
namespace: nextcloud
|
||||||
|
spec:
|
||||||
|
type: NodePort
|
||||||
|
selector:
|
||||||
|
app: collabora
|
||||||
|
ports:
|
||||||
|
- port: 9980
|
||||||
|
targetPort: 9980
|
||||||
|
nodePort: 30980
|
||||||
@@ -28,10 +28,17 @@ spec:
|
|||||||
value: nextcloud
|
value: nextcloud
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 3306
|
- containerPort: 3306
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
memory: "256Mi"
|
||||||
|
cpu: "250m"
|
||||||
|
limits:
|
||||||
|
memory: "512Mi"
|
||||||
|
cpu: "500m"
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: mariadb-data
|
- name: mariadb-data
|
||||||
mountPath: /var/lib/mysql
|
mountPath: /var/lib/mysql
|
||||||
volumes:
|
volumes:
|
||||||
- name: mariadb-data
|
- name: mariadb-data
|
||||||
persistentVolumeClaim:
|
persistentVolumeClaim:
|
||||||
claimName: pvc-mariadb
|
claimName: nextcloud-mariadb-pvc
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: PersistentVolumeClaim
|
kind: PersistentVolumeClaim
|
||||||
metadata:
|
metadata:
|
||||||
name: pvc-mariadb
|
name: nextcloud-mariadb-pvc
|
||||||
namespace: nextcloud
|
namespace: nextcloud
|
||||||
spec:
|
spec:
|
||||||
accessModes:
|
accessModes:
|
||||||
@@ -14,7 +14,7 @@ spec:
|
|||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: PersistentVolume
|
kind: PersistentVolume
|
||||||
metadata:
|
metadata:
|
||||||
name: pv-mariadb
|
name: nextcloud-mariadb-pv
|
||||||
labels:
|
labels:
|
||||||
app: mariadb
|
app: mariadb
|
||||||
spec:
|
spec:
|
||||||
@@ -26,7 +26,7 @@ spec:
|
|||||||
storageClassName: local-path
|
storageClassName: local-path
|
||||||
claimRef:
|
claimRef:
|
||||||
namespace: nextcloud
|
namespace: nextcloud
|
||||||
name: pvc-mariadb
|
name: nextcloud-mariadb-pvc
|
||||||
hostPath:
|
hostPath:
|
||||||
path: /var/lib/mariadb-data
|
path: /var/lib/nextcloud/mariadb-data
|
||||||
type: DirectoryOrCreate
|
type: DirectoryOrCreate
|
||||||
|
|||||||
31
k3s/apps/Nextcloud/manifest/nextcloud-apps-pv-pvc.yaml
Normal file
31
k3s/apps/Nextcloud/manifest/nextcloud-apps-pv-pvc.yaml
Normal file
@@ -0,0 +1,31 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
name: nextcloud-apps-pvc
|
||||||
|
namespace: nextcloud
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 1Gi
|
||||||
|
volumeName: nextcloud-apps-pv
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolume
|
||||||
|
metadata:
|
||||||
|
name: nextcloud-apps-pv
|
||||||
|
labels:
|
||||||
|
app: nextcloud
|
||||||
|
spec:
|
||||||
|
capacity:
|
||||||
|
storage: 1Gi
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
persistentVolumeReclaimPolicy: Retain
|
||||||
|
claimRef:
|
||||||
|
namespace: nextcloud
|
||||||
|
name: nextcloud-apps-pvc
|
||||||
|
hostPath:
|
||||||
|
path: /var/lib/nextcloud/custom_apps
|
||||||
|
type: DirectoryOrCreate
|
||||||
32
k3s/apps/Nextcloud/manifest/nextcloud-config-pv-pvc.yaml
Normal file
32
k3s/apps/Nextcloud/manifest/nextcloud-config-pv-pvc.yaml
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
name: nextcloud-config-pvc
|
||||||
|
namespace: nextcloud
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 5Gi
|
||||||
|
storageClassName: local-path # match mariadb local-path style
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolume
|
||||||
|
metadata:
|
||||||
|
name: pv-nextcloud-config
|
||||||
|
labels:
|
||||||
|
app: nextcloud
|
||||||
|
spec:
|
||||||
|
capacity:
|
||||||
|
storage: 5Gi
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
persistentVolumeReclaimPolicy: Retain
|
||||||
|
storageClassName: local-path
|
||||||
|
claimRef:
|
||||||
|
namespace: nextcloud
|
||||||
|
name: nextcloud-config-pvc
|
||||||
|
hostPath:
|
||||||
|
path: /var/lib/nextcloud/nextcloud-config
|
||||||
|
type: DirectoryOrCreate
|
||||||
21
k3s/apps/Nextcloud/manifest/nextcloud-cron-job.yaml
Normal file
21
k3s/apps/Nextcloud/manifest/nextcloud-cron-job.yaml
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
apiVersion: batch/v1
|
||||||
|
kind: CronJob
|
||||||
|
metadata:
|
||||||
|
name: nextcloud-webcron
|
||||||
|
namespace: nextcloud
|
||||||
|
spec:
|
||||||
|
schedule: "*/5 * * * *" # alle 5 Minuten
|
||||||
|
successfulJobsHistoryLimit: 3
|
||||||
|
failedJobsHistoryLimit: 3
|
||||||
|
jobTemplate:
|
||||||
|
spec:
|
||||||
|
activeDeadlineSeconds: 300
|
||||||
|
template:
|
||||||
|
spec:
|
||||||
|
restartPolicy: Never
|
||||||
|
containers:
|
||||||
|
- name: webcron
|
||||||
|
image: curlimages/curl:8.5.0
|
||||||
|
command: ["/bin/sh", "-c"]
|
||||||
|
args:
|
||||||
|
- 'until curl -fsS http://nextcloud.nextcloud.svc.cluster.local/status.php; do echo "waiting for nextcloud..."; sleep 5; done; curl -s -o /dev/null -w "%{http_code}\n" http://nextcloud.nextcloud.svc.cluster.local/cron.php'
|
||||||
@@ -38,18 +38,36 @@ spec:
|
|||||||
- name: REDIS_HOST
|
- name: REDIS_HOST
|
||||||
value: redis.nextcloud.svc.cluster.local
|
value: redis.nextcloud.svc.cluster.local
|
||||||
- name: NEXTCLOUD_TRUSTED_DOMAINS
|
- name: NEXTCLOUD_TRUSTED_DOMAINS
|
||||||
value: "henryathome.home64.de,192.168.178.0/24,192.168.178.138"
|
value: "henryathome.home64.de,192.168.178.0/24,192.168.178.138,nextcloud.nextcloud.svc.cluster.local"
|
||||||
# resources:
|
- name: TRUSTED_PROXIES
|
||||||
# requests:
|
value: "192.168.178.120"
|
||||||
# memory: "512Mi"
|
- name: OVERWRITEHOST
|
||||||
# cpu: "250m"
|
value: "henryathome.home64.de"
|
||||||
# limits:
|
- name: OVERWRITEPROTOCOL
|
||||||
# memory: "1Gi"
|
value: "https"
|
||||||
# cpu: "1000m"
|
- name: OVERWRITECLIURL
|
||||||
|
value: "https://henryathome.home64.de"
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
memory: "512Mi"
|
||||||
|
cpu: "250m"
|
||||||
|
limits:
|
||||||
|
memory: "4Gi"
|
||||||
|
cpu: "3000m"
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: data
|
- name: data
|
||||||
mountPath: /var/www/html/data # angepasst auf Standard Nextcloud Datadir
|
mountPath: /var/www/html/data
|
||||||
|
- name: config
|
||||||
|
mountPath: /var/www/html/config
|
||||||
|
- name: apps
|
||||||
|
mountPath: /var/www/html/custom_apps
|
||||||
volumes:
|
volumes:
|
||||||
- name: data
|
- name: data
|
||||||
persistentVolumeClaim:
|
persistentVolumeClaim:
|
||||||
claimName: nextcloud-data-pvc
|
claimName: nextcloud-data-pvc
|
||||||
|
- name: config
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: nextcloud-config-pvc
|
||||||
|
- name: apps
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: nextcloud-apps-pvc
|
||||||
@@ -112,4 +112,4 @@ spec:
|
|||||||
claimName: immich-library-pvc
|
claimName: immich-library-pvc
|
||||||
- name: ext-library
|
- name: ext-library
|
||||||
persistentVolumeClaim:
|
persistentVolumeClaim:
|
||||||
claimName: photoprism-storage
|
claimName: photoprism-library-pvc
|
||||||
|
|||||||
13
k3s/apps/photo/photoprism/photoprism-storrage-pvc.yaml
Normal file
13
k3s/apps/photo/photoprism/photoprism-storrage-pvc.yaml
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
name: photoprism-library-pvc
|
||||||
|
namespace: photoprism
|
||||||
|
spec:
|
||||||
|
storageClassName: nfs
|
||||||
|
volumeName: photos-nfs-pv
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteMany
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 50Gi
|
||||||
@@ -1,31 +1,3 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: PersistentVolumeClaim
|
|
||||||
metadata:
|
|
||||||
name: photoprism-storage
|
|
||||||
namespace: photoprism
|
|
||||||
spec:
|
|
||||||
storageClassName: nfs
|
|
||||||
volumeName: nfs-pv
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteMany
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: 50Gi
|
|
||||||
---
|
|
||||||
#apiVersion: v1
|
|
||||||
#kind: PersistentVolumeClaim
|
|
||||||
#metadata:
|
|
||||||
# name: photoprism-originals
|
|
||||||
# namespace: photoprism
|
|
||||||
#spec:
|
|
||||||
# storageClassName: nfs
|
|
||||||
# volumeName: nfs-pv
|
|
||||||
# accessModes:
|
|
||||||
# - ReadWriteMany
|
|
||||||
# resources:
|
|
||||||
# requests:
|
|
||||||
# storage: 100Gi
|
|
||||||
---
|
|
||||||
apiVersion: apps/v1
|
apiVersion: apps/v1
|
||||||
kind: Deployment
|
kind: Deployment
|
||||||
metadata:
|
metadata:
|
||||||
@@ -101,7 +73,7 @@ spec:
|
|||||||
# memory: "512Mi"
|
# memory: "512Mi"
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- mountPath: /photoprism/
|
- mountPath: /photoprism/
|
||||||
name: photoprism-storage
|
name: photoprism-library-pvc
|
||||||
# - mountPath: /photoprism/storage
|
# - mountPath: /photoprism/storage
|
||||||
# name: photoprism-storage
|
# name: photoprism-storage
|
||||||
# - mountPath: /photoprism/originals
|
# - mountPath: /photoprism/originals
|
||||||
@@ -111,9 +83,9 @@ spec:
|
|||||||
# runAsUser: 1000
|
# runAsUser: 1000
|
||||||
# runAsGroup: 1000
|
# runAsGroup: 1000
|
||||||
volumes:
|
volumes:
|
||||||
- name: photoprism-storage
|
- name: photoprism-library-pvc
|
||||||
persistentVolumeClaim:
|
persistentVolumeClaim:
|
||||||
claimName: photoprism-storage
|
claimName: photoprism-library-pvc
|
||||||
# - name: photoprism-originals
|
# - name: photoprism-originals
|
||||||
# persistentVolumeClaim:
|
# persistentVolumeClaim:
|
||||||
# claimName: photoprism-originals
|
# claimName: photoprism-originals
|
||||||
|
|||||||
17
k3s/apps/photo/photos-pv.yaml
Normal file
17
k3s/apps/photo/photos-pv.yaml
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolume
|
||||||
|
metadata:
|
||||||
|
name: photos-nfs-pv
|
||||||
|
spec:
|
||||||
|
capacity:
|
||||||
|
storage: 200Gi
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteMany
|
||||||
|
persistentVolumeReclaimPolicy: Retain
|
||||||
|
storageClassName: nfs
|
||||||
|
nfs:
|
||||||
|
server: 192.168.178.186
|
||||||
|
path: /volume1/Photos
|
||||||
|
mountOptions:
|
||||||
|
- hard
|
||||||
|
- nfsvers=4
|
||||||
Reference in New Issue
Block a user