Skip to content

Commit

Permalink
enable-paperless-ai
Browse files Browse the repository at this point in the history
  • Loading branch information
rwlove committed Jan 7, 2025
1 parent 4946729 commit 7932508
Show file tree
Hide file tree
Showing 8 changed files with 122 additions and 153 deletions.
113 changes: 0 additions & 113 deletions .archive/kubernetes/paperless/app/helmrelease.yaml

This file was deleted.

32 changes: 0 additions & 32 deletions .archive/kubernetes/paperless/app/nfs-pvc.yaml

This file was deleted.

1 change: 1 addition & 0 deletions kubernetes/main/apps/collab/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ./obsidian-couchdb/ks.yaml
- ./paperless-ai/ks.yaml
73 changes: 73 additions & 0 deletions kubernetes/main/apps/collab/paperless-ai/app/helmrelease.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/fluxcd-community/flux2-schemas/main/helmrelease-helm-v2beta2.json
apiVersion: helm.toolkit.fluxcd.io/v2
kind: HelmRelease
metadata:
name: paperless-ai
spec:
interval: 30m
chart:
spec:
chart: app-template
version: 3.3.2
interval: 30m
sourceRef:
kind: HelmRepository
name: bjw-s-charts
namespace: flux-system

values:
controllers:
main:
type: statefulset

initContainers:
init-db:
image:
repository: clusterzx/paperless-ai
tag: 1.4.6@sha256:ed24b8aa1392cae598f376f1cc13074e58fa9913fd8594e45a640713f11c24c4

containers:
main:
image:
repository: ghcr.io/paperless-ngx/paperless-ngx
tag: 2.11.6

resources:
requests:
cpu: 11m
memory: 2048Mi
limits:
memory: 2048Mi

service:
main:
controller: main
ports:
http:
port: &httpPort 8000

ingress:
main:
className: internal
annotations:
hajimari.io/enable: "true"
hajimari.io/appName: "Paperless"
hajimari.io/icon: arcticons:paperless
hajimari.io/group: "collab"
hajimari.io/instance: "admin"
hosts:
- host: &host paperless.${SECRET_DOMAIN}
paths:
- path: /
service:
identifier: main
port: *httpPort

persistence:
library:
existingClaim: paperless-data-pvc
advancedMounts:
main:
main:
- path: /app/data
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,5 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ./externalsecret.yaml
- ./helmrelease.yaml
- ./nfs-pvc.yaml
- ./longhorn-pvc.yaml
42 changes: 42 additions & 0 deletions kubernetes/main/apps/collab/paperless-ai/app/longhorn-pvc.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
namespace: media
name: paperless-data-pvc
labels:
type: longhorn
spec:
accessModes:
- ReadWriteOnce
volumeMode: Filesystem
resources:
requests:
storage: 100Gi
volumeName: paperless-data-pv
storageClassName: paperless-data-storage-class

---
apiVersion: v1
kind: PersistentVolume
metadata:
name: paperless-data-pv
labels:
type: longhorn
recurring-job-group.longhorn.io/weekly-backup: enabled
recurring-job-group.longhorn.io/daily-snapshot: enabled
spec:
capacity:
storage: 100Gi
volumeMode: Filesystem
accessModes:
- ReadWriteOnce
persistentVolumeReclaimPolicy: Retain
storageClassName: paperless-data-storage-class
csi:
driver: driver.longhorn.io
fsType: xfs
volumeAttributes:
numberOfReplicas: "2"
staleReplicaTimeout: "2880"
volumeHandle: paperless-data-xfs
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,20 @@
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
name: &appname collab-paperless
name: collab-paperless-ai
namespace: flux-system
spec:
targetNamespace: collab
commonMetadata:
labels:
app.kubernetes.io/name: paperless
app.kubernetes.io/name: &appname paperless-ai
interval: 30m
path: "./kubernetes/main/apps/collab/paperless/app"
path: "./kubernetes/main/apps/collab/paperless-ai/app"
prune: true
sourceRef:
kind: GitRepository
name: home-ops-kubernetes
wait: false
dependsOn:
- name: databases-dragonfly-cluster
- name: storage-rook-ceph-cluster
- name: system-external-secrets-stores
- name: storage-longhorn
- name: ai-ollama

0 comments on commit 7932508

Please sign in to comment.