From 27e5034c14afad3344a9ce836839f12094f33a1d Mon Sep 17 00:00:00 2001 From: Mans Ziesel Date: Sun, 27 Oct 2024 11:39:45 +0100 Subject: [PATCH] add rdtclient --- .../mediaserver-deployment-rdtclient.yaml | 46 +++++++++++++++++++ .../mediaserver-rdtclient-deployment.yaml | 46 +++++++++++++++++++ .../base/mediaserver-rdtclient-ingress.yaml | 12 +++++ .../base/mediaserver-rdtclient-pvc.yaml | 23 ++++++++++ .../base/mediaserver-rdtclient-svc.yaml | 11 +++++ 5 files changed, 138 insertions(+) create mode 100644 mediaserver/base/mediaserver-deployment-rdtclient.yaml create mode 100644 mediaserver/base/mediaserver-rdtclient-deployment.yaml create mode 100644 mediaserver/base/mediaserver-rdtclient-ingress.yaml create mode 100644 mediaserver/base/mediaserver-rdtclient-pvc.yaml create mode 100644 mediaserver/base/mediaserver-rdtclient-svc.yaml diff --git a/mediaserver/base/mediaserver-deployment-rdtclient.yaml b/mediaserver/base/mediaserver-deployment-rdtclient.yaml new file mode 100644 index 0000000..722fbff --- /dev/null +++ b/mediaserver/base/mediaserver-deployment-rdtclient.yaml @@ -0,0 +1,46 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: rdtclient + labels: + app: rdtclient +spec: + replicas: 1 + selector: + matchLabels: + app: rdtclient + template: + metadata: + labels: + app: rdtclient + annotations: + spec: + volumes: + - name: rdtclient-data + persistentVolumeClaim: + claimName: mediaserver-rdtclient-data-pvc + - name: rdtclient-downloads + persistentVolumeClaim: + claimName: mediaserver-rdtclient-downloads-pvc + containers: + - name: rdtclient + image: rogerfar/rdtclient + resources: + requests: + cpu: 1 + memory: 512Mi + ports: + - name: web + containerPort: 6500 + env: + - name: PUID + value: "1000" + - name: PGID + value: "1000" + - name: TZ + value: Europe/Amsterdam + volumeMounts: + - mountPath: /data/downloads + name: rdtclient-downloads + - mountPath: /data/db + name: rdtclient-data diff --git a/mediaserver/base/mediaserver-rdtclient-deployment.yaml b/mediaserver/base/mediaserver-rdtclient-deployment.yaml new file mode 100644 index 0000000..722fbff --- /dev/null +++ b/mediaserver/base/mediaserver-rdtclient-deployment.yaml @@ -0,0 +1,46 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: rdtclient + labels: + app: rdtclient +spec: + replicas: 1 + selector: + matchLabels: + app: rdtclient + template: + metadata: + labels: + app: rdtclient + annotations: + spec: + volumes: + - name: rdtclient-data + persistentVolumeClaim: + claimName: mediaserver-rdtclient-data-pvc + - name: rdtclient-downloads + persistentVolumeClaim: + claimName: mediaserver-rdtclient-downloads-pvc + containers: + - name: rdtclient + image: rogerfar/rdtclient + resources: + requests: + cpu: 1 + memory: 512Mi + ports: + - name: web + containerPort: 6500 + env: + - name: PUID + value: "1000" + - name: PGID + value: "1000" + - name: TZ + value: Europe/Amsterdam + volumeMounts: + - mountPath: /data/downloads + name: rdtclient-downloads + - mountPath: /data/db + name: rdtclient-data diff --git a/mediaserver/base/mediaserver-rdtclient-ingress.yaml b/mediaserver/base/mediaserver-rdtclient-ingress.yaml new file mode 100644 index 0000000..c0c0349 --- /dev/null +++ b/mediaserver/base/mediaserver-rdtclient-ingress.yaml @@ -0,0 +1,12 @@ +apiVersion: traefik.io/v1alpha1 +kind: IngressRoute +metadata: + name: mediaserver-rdtclient-ingressroute +spec: + routes: + - match: Host(`rdtclient.k8s.mziesel.nl`) + kind: Rule + services: + - name: mediaserver-rdtclient + port: web + tls: {} diff --git a/mediaserver/base/mediaserver-rdtclient-pvc.yaml b/mediaserver/base/mediaserver-rdtclient-pvc.yaml new file mode 100644 index 0000000..761eab9 --- /dev/null +++ b/mediaserver/base/mediaserver-rdtclient-pvc.yaml @@ -0,0 +1,23 @@ +kind: PersistentVolumeClaim +apiVersion: v1 +metadata: + name: mediaserver-rdtclient-data-pvc +spec: + storageClassName: nfs-client + accessModes: + - ReadWriteMany + resources: + requests: + storage: 2Gi +--- +kind: PersistentVolumeClaim +apiVersion: v1 +metadata: + name: mediaserver-rdtclient-downloads-pvc +spec: + storageClassName: nfs-client + accessModes: + - ReadWriteMany + resources: + requests: + storage: 100Gi diff --git a/mediaserver/base/mediaserver-rdtclient-svc.yaml b/mediaserver/base/mediaserver-rdtclient-svc.yaml new file mode 100644 index 0000000..36cc561 --- /dev/null +++ b/mediaserver/base/mediaserver-rdtclient-svc.yaml @@ -0,0 +1,11 @@ +apiVersion: v1 +kind: Service +metadata: + name: mediaserver-rdtclient +spec: + ports: + - name: web + port: 80 + targetPort: web + selector: + app: rdtclient