Browse Source

add copyparty, pulsarr, tronbyt

Josh Bicking 3 weeks ago
parent
commit
db8b36c1b3
9 changed files with 390 additions and 20 deletions
  1. 2 0
      cloudflared.yaml
  2. 15 0
      copyparty-pvc.yaml
  3. 143 0
      copyparty.yaml
  4. 15 0
      pulsarr-pvc.yaml
  5. 93 0
      pulsarr.yaml
  6. 18 18
      rook/rook-ceph-operator-values.yaml
  7. 2 2
      seedbox-nfs.yaml
  8. 14 0
      tronbyt-pvc.yaml
  9. 88 0
      tronbyt.yaml

+ 2 - 0
cloudflared.yaml

@@ -74,6 +74,8 @@ data:
       service: http://ntfy-service.ntfy.svc.cluster.local:80
     - hostname: paperless.jibby.org
       service: http://paperless-service.paperless.svc.cluster.local:8000
+    - hostname: tronbyt.jibby.org
+      service: http://tronbyt-service.tronbyt.svc.cluster.local:8000
     # - hostname: mastodon.jibby.org
     #   service: http://mastodon-service.mastodon.svc.cluster.local:3000
     # - hostname: streaming-mastodon.jibby.org

+ 15 - 0
copyparty-pvc.yaml

@@ -0,0 +1,15 @@
+---
+apiVersion: v1
+kind: PersistentVolumeClaim
+metadata:
+  name: copyparty-pvc
+  namespace: copyparty
+  labels:
+    app: copyparty
+spec:
+  storageClassName: ceph-block
+  accessModes:
+    - ReadWriteOnce
+  resources:
+    requests:
+      storage: 500Gi

+ 143 - 0
copyparty.yaml

@@ -0,0 +1,143 @@
+---
+apiVersion: v1
+kind: Namespace
+metadata:
+    name: copyparty
+---
+apiVersion: apps/v1
+kind: Deployment
+metadata:
+  name: copyparty
+  namespace: copyparty
+spec:
+  strategy:
+    type: Recreate
+  selector:
+    matchLabels:
+      app: copyparty
+  replicas: 1
+  template:
+    metadata:
+      labels:
+        app: copyparty
+      annotations:
+        backup.velero.io/backup-volumes-excludes: copyparty
+    spec:
+      containers:
+      - name: copyparty
+        image: copyparty/ac
+        imagePullPolicy: Always
+        ports:
+        - containerPort: 3923
+          name: http-web-svc
+        volumeMounts:
+        - mountPath: "/w"
+          name: copyparty
+        - name: accounts
+          mountPath: /cfg/accounts.conf
+          subPath: accounts.conf
+        - name: config-default
+          mountPath: /cfg/default.conf
+          subPath: default.conf
+      volumes:
+      - name: copyparty
+        persistentVolumeClaim:
+          claimName: copyparty-pvc
+      - name: config-default
+        configMap:
+          name: copyparty-config
+          configMap:
+          items:
+          - key: default.conf
+            path: default.conf
+      - name: accounts
+        secret:
+          secretName: copyparty-secret-accounts
+---
+apiVersion: v1
+kind: ConfigMap
+metadata:
+  name: copyparty-config
+  namespace: copyparty
+data:
+  default.conf: |
+    [global]
+      p: 3923
+      e2dsa  # enable file indexing and filesystem scanning
+      e2ts   # and enable multimedia indexing
+      z, qr  # and zeroconf and qrcode (you can comma-separate arguments)
+      name: copyparty.jibby.org
+
+      qrs    # HTTPS QR code
+      qri: copyparty.jibby.org
+
+      xff-src: lan
+      xff-hdr: cf-connecting-ip
+
+      dav-auth
+    
+    # create volumes:
+    [/pub]
+      /w/pub 
+      accs:
+        r: *
+        A: josh
+      flags:
+        og
+        #og_ua: '(Discord|Twitter|Slack)bot' # doesn't work w/ signal
+    
+    [/priv]
+      /w/priv
+      accs:
+        A: josh
+
+    [/priv/Archive/Signal]
+      /w/priv/Archive/Signal
+      accs:
+        A: josh
+      flags:
+        lifetime: 604800  # 1wk
+        daw
+
+    [/priv/Archive/SMS]
+      /w/priv/Archive/SMS
+      accs:
+        A: josh
+      flags:
+        lifetime: 7257600  # 3mo
+        daw
+---
+apiVersion: v1
+kind: Service
+metadata:
+  name: copyparty-service
+  namespace: copyparty
+spec:
+  selector:
+    app: copyparty
+  type: ClusterIP
+  ports:
+  - name: copyparty-web-port
+    protocol: TCP
+    port: 3923
+    targetPort: http-web-svc
+---
+apiVersion: networking.k8s.io/v1
+kind: Ingress
+metadata:
+  name: copyparty
+  namespace: copyparty
+  annotations:
+    traefik.ingress.kubernetes.io/router.entrypoints: websecure
+spec:
+  rules:
+    - host: copyparty.jibby.org
+      http:
+        paths:
+          - path: /
+            pathType: Prefix
+            backend:
+              service:
+                name: copyparty-service
+                port:
+                  number: 3923

+ 15 - 0
pulsarr-pvc.yaml

@@ -0,0 +1,15 @@
+apiVersion: v1
+kind: PersistentVolumeClaim
+metadata:
+  name: pulsarr-pvc
+  namespace: plex
+  labels:
+    app: pulsarr
+spec:
+  storageClassName: ceph-block-ssd
+  accessModes:
+    - ReadWriteOnce
+  resources:
+    requests:
+      storage: 1Gi
+

+ 93 - 0
pulsarr.yaml

@@ -0,0 +1,93 @@
+---
+apiVersion: apps/v1
+kind: Deployment
+metadata:
+  name: pulsarr
+  namespace: plex
+spec:
+  strategy:
+    type: Recreate
+  selector:
+    matchLabels:
+      app: pulsarr
+  replicas: 1
+  template:
+    metadata:
+      labels:
+        app: pulsarr
+    spec:
+      containers:
+      - name: pulsarr
+        image: lakker/pulsarr:latest
+        imagePullPolicy: Always
+        ports:
+        - containerPort: 3003
+          name: http-web-svc
+        volumeMounts:
+        - mountPath: "/app/data"
+          name: data
+        - mountPath: /app/.env
+          subPath: .env
+          name: env
+        resources:
+          requests:
+            memory: "0"
+          limits:
+            memory: "1Gi"
+      volumes:
+      - name: env
+        configMap:
+          name: pulsarr-env
+      - name: data
+        persistentVolumeClaim:
+          claimName: pulsarr-pvc
+---
+apiVersion: v1
+kind: ConfigMap
+metadata:
+  name: pulsarr-env
+  namespace: plex
+data:
+  .env: |
+    baseUrl=https://pulsarr.lan.jibby.org
+    port=3003
+    TZ=America/New_York
+    logLevel=info
+    NODE_ARGS=--log-both
+    cookieSecured=true
+---
+apiVersion: v1
+kind: Service
+metadata:
+  name: pulsarr-service
+  namespace: plex
+spec:
+  selector:
+    app: pulsarr
+  type: ClusterIP
+  ports:
+  - name: pulsarr-web-port
+    protocol: TCP
+    port: 3003
+    targetPort: http-web-svc
+---
+apiVersion: networking.k8s.io/v1
+kind: Ingress
+metadata:
+  name: pulsarr
+  namespace: plex
+  annotations:
+    traefik.ingress.kubernetes.io/router.entrypoints: websecure
+    traefik.ingress.kubernetes.io/router.middlewares: kube-system-lanonly@kubernetescrd
+spec:
+  rules:
+    - host: pulsarr.lan.jibby.org
+      http:
+        paths:
+          - path: /
+            pathType: Prefix
+            backend:
+              service:
+                name: pulsarr-service
+                port:
+                  number: 3003

+ 18 - 18
rook/rook-ceph-operator-values.yaml

@@ -294,43 +294,43 @@ csi:
     - name : csi-provisioner
       resource:
         requests:
-          memory: 128Mi
-          cpu: 100m
+          memory: 0
+          cpu: 0
         limits:
           memory: 256Mi
     - name : csi-resizer
       resource:
         requests:
-          memory: 128Mi
-          cpu: 100m
+          memory: 0
+          cpu: 0
         limits:
           memory: 256Mi
     - name : csi-attacher
       resource:
         requests:
-          memory: 128Mi
-          cpu: 100m
+          memory: 0
+          cpu: 0
         limits:
           memory: 256Mi
     - name : csi-snapshotter
       resource:
         requests:
-          memory: 128Mi
-          cpu: 100m
+          memory: 0
+          cpu: 0
         limits:
           memory: 256Mi
     - name : csi-cephfsplugin
       resource:
         requests:
-          memory: 512Mi
-          cpu: 250m
+          memory: 0
+          cpu: 0
         limits:
           memory: 1Gi
     - name : liveness-prometheus
       resource:
         requests:
-          memory: 128Mi
-          cpu: 50m
+          memory: 0
+          cpu: 0
         limits:
           memory: 256Mi
 
@@ -340,22 +340,22 @@ csi:
     - name : driver-registrar
       resource:
         requests:
-          memory: 128Mi
-          cpu: 50m
+          memory: 0
+          cpu: 0
         limits:
           memory: 256Mi
     - name : csi-cephfsplugin
       resource:
         requests:
-          memory: 512Mi
-          cpu: 250m
+          memory: 0
+          cpu: 0
         limits:
           memory: 1Gi
     - name : liveness-prometheus
       resource:
         requests:
-          memory: 128Mi
-          cpu: 50m
+          memory: 0
+          cpu: 0
         limits:
           memory: 256Mi
 

+ 2 - 2
seedbox-nfs.yaml

@@ -40,7 +40,7 @@ spec:
       hostNetwork: true
       containers:
       - name: nfs
-        image: erichough/nfs-server
+        image: erichough/nfs-server:2.2.1
         ports:
         - containerPort: 2049
           name: nfs
@@ -72,7 +72,7 @@ metadata:
   namespace: nfs
 data:
   exports: |
-    /data 172.16.69.30 172.16.69.31 172.16.69.32 172.16.69.52 172.16.69.253 10.42.0.0/16
+    /data 172.16.69.30(rw) 172.16.69.31(rw) 172.16.69.32(rw) 172.16.69.52(rw) 172.16.69.253(rw) 10.42.0.0/16(rw)
 
 # Testing NFS access from within a pod
 # ---

+ 14 - 0
tronbyt-pvc.yaml

@@ -0,0 +1,14 @@
+apiVersion: v1
+kind: PersistentVolumeClaim
+metadata:
+  name: tronbyt-pvc
+  namespace: tronbyt
+  labels:
+    app: tronbyt
+spec:
+  storageClassName: ceph-block-ssd
+  accessModes:
+    - ReadWriteOnce
+  resources:
+    requests:
+      storage: 1Gi

+ 88 - 0
tronbyt.yaml

@@ -0,0 +1,88 @@
+---
+apiVersion: v1
+kind: Namespace
+metadata:
+    name: tronbyt
+---
+apiVersion: apps/v1
+kind: Deployment
+metadata:
+  name: tronbyt
+  namespace: tronbyt
+spec:
+  strategy:
+    type: Recreate
+  selector:
+    matchLabels:
+      app: tronbyt
+  replicas: 1
+  template:
+    metadata:
+      labels:
+        app: tronbyt
+      annotations:
+        backup.velero.io/backup-volumes-excludes: tronbyt,seedbox,scratch
+    spec:
+      containers:
+      - name: tronbyt
+        image: ghcr.io/tronbyt/server:latest
+        imagePullPolicy: Always
+        ports:
+        - containerPort: 8000
+          name: http-web-svc
+        env:
+        - name: SERVER_HOSTNAME
+          value: tronbyt.jibby.org
+        - name: SERVER_PORT
+          value: "8000"
+        - name: PRODUCTION
+          value: "1"
+        - name: TZ
+          value: America/New_York
+        volumeMounts:
+        - mountPath: "/app/data"
+          name: data
+          subPath: data
+        - mountPath: "/app/users"
+          name: data
+          subPath: users
+      volumes:
+      - name: data
+        persistentVolumeClaim:
+          claimName: tronbyt-pvc
+---
+apiVersion: v1
+kind: Service
+metadata:
+  name: tronbyt-service
+  namespace: tronbyt
+spec:
+  selector:
+    app: tronbyt
+  type: ClusterIP
+  ports:
+  - name: tronbyt-web-port
+    protocol: TCP
+    port: 8000
+    targetPort: http-web-svc
+---
+apiVersion: networking.k8s.io/v1
+kind: Ingress
+metadata:
+  name: tronbyt
+  namespace: tronbyt
+  annotations:
+    traefik.ingress.kubernetes.io/router.entrypoints: websecure
+spec:
+  rules:
+    - host: tronbyt.jibby.org
+      http:
+        paths:
+          - path: /
+            pathType: Prefix
+            backend:
+              service:
+                name: tronbyt-service
+                port:
+                  number: 8000
+