Files
k3s-at-home/clusters/default/tools/paperless-ngx/paperless-ngx.yml
aggarwalakshun ae49f05be3
All checks were successful
renovate / renovate (push) Successful in 2m43s
split db and app into two deployments
2025-12-10 03:39:49 +05:30

70 lines
2.0 KiB
YAML

---
apiVersion: apps/v1
kind: Deployment
metadata:
name: paperless-ngx
namespace: tools
spec:
strategy:
type: Recreate
selector:
matchLabels:
app: paperless-ngx
template:
metadata:
labels:
app: paperless-ngx
spec:
initContainers:
- name: wait-for-redis
image: busybox:latest
command: ['sh', '-c', 'until nc -z paperless-ngx-db-service 6379; do echo waiting for redis; sleep 2; done;']
containers:
- name: paperless-ngx
image: ghcr.io/paperless-ngx/paperless-ngx:2.20.1
ports:
- containerPort: 8000
env:
- name: PAPERLESS_REDIS
value: "redis://paperless-ngx-db-service:6379"
- name: PAPERLESS_URL
valueFrom:
secretKeyRef:
name: paperless-secrets
key: PAPERLESS_URL
- name: PAPERLESS_CSRF_TRUSTED_ORIGINS
valueFrom:
secretKeyRef:
name: paperless-secrets
key: PAPERLESS_CSRF_TRUSTED_ORIGINS
- name: PAPERLESS_CORS_ALLOWED_HOSTS
valueFrom:
secretKeyRef:
name: paperless-secrets
key: PAPERLESS_URL
- name: PAPERLESS_TIME_ZONE
value: "Asia/Kolkata"
- name: PAPERLESS_TIKA_ENABLED
value: "1"
- name: PAPERLESS_TIKA_ENDPOINT
value: "http://tika-service:9998"
- name: PAPERLESS_TIKA_GOTENBERG_ENDPOINT
value: "http://gotenberg-service:3000"
volumeMounts:
- name: data
mountPath: /usr/src/paperless/data
subPath: data
- name: data
mountPath: usr/src/paperless/media
subPath: media
- name: data
mountPath: /usr/src/paperless/export
subPath: export
- name: data
mountPath: /usr/src/paperless/consume
subPath: consume
volumes:
- name: data
persistentVolumeClaim:
claimName: paperless-longhorn