Refactor paperless-ai Helm chart for improved configuration
Some checks failed
Build Helm Chart / helm-package (push) Failing after 3s

This update substantially refactors the paperless-ai Helm chart.
Key changes include:

- Complete removal of outdated files: `.helmignore`, `LICENSE`,
  `README.adoc`, and several template files like `configfileConfigmap.yaml`,
  `configmap.yaml`, `dataPvc.yaml`, `envfileSecret.yaml`,
  `openAiApiSecret.yaml`, `paperlessApiSecret.yaml`, and others.

- Introduction of a new Persistent Volume Claim configuration in
  `pvc.yaml` to simplify storage management.

- Significant updates to `Chart.yaml` for better metadata, including
  a new maintainer and project description in German.

- Enhancements to the main deployment template in `deployment.yaml`,
  focusing on clarity and proper utilization of Kubernetes security
  contexts, environment variables, and container properties.

- Updated service definitions in `service.yaml` with better labels
  and service properties.

- Refined the `ingress.yaml` to improve external service access
  management, including annotations for potential customization.

These changes were implemented to modernize the Helm chart based on
the current best practices, improve user experience, and set a
foundation for future enhancements. There are no breaking changes to
the existing user configurations.
This commit is contained in:
2025-07-06 09:02:17 +02:00
parent c18b5c7514
commit ba732eb734
19 changed files with 202 additions and 504 deletions

View File

@ -1,73 +1,60 @@
# Default values for paperless-ai.
# This is a YAML-formatted file.
# Declare variables to be passed into your templates.
# This will set the replicaset count more information can be found here: https://kubernetes.io/docs/concepts/workloads/controllers/replicaset/
# Please keep this value to 1, while many instances running a crontab could lead to unknown results.
replicaCount: 1
# This sets the container image more information can be found here: https://kubernetes.io/docs/concepts/containers/images/
image:
repository: clusterzx/paperless-ai
# This sets the pull policy for images.
pullPolicy: IfNotPresent
# Overrides the image tag whose default is the chart appVersion.
# Use latest or nightly to be up2date.
tag: ""
# This is for the secretes for pulling an image from a private repository more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
imagePullSecrets: []
# This is to override the chart name.
nameOverride: ""
fullnameOverride: ""
# This is for setting Kubernetes Annotations to a Pod.
# For more information checkout: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/
podAnnotations: {}
# This is for setting Kubernetes Labels to a Pod.
# For more information checkout: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/
podLabels: {}
podSecurityContext: {}
# fsGroup: 2000
securityContext: {}
# capabilities:
# drop:
# - ALL
# readOnlyRootFilesystem: true
# runAsNonRoot: true
# runAsUser: 1000
# This is for setting up a service more information can be found here: https://kubernetes.io/docs/concepts/services-networking/service/
service:
# This sets the service type more information can be found here: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types
type: ClusterIP
# This sets the ports more information can be found here: https://kubernetes.io/docs/concepts/services-networking/service/#field-spec-ports
port: 3000
# This block is for setting up the ingress for more information can be found here: https://kubernetes.io/docs/concepts/services-networking/ingress/
ingress:
enabled: false
className: ""
serviceAccount:
create: true
annotations: {}
# kubernetes.io/ingress.class: nginx
# kubernetes.io/tls-acme: "true"
hosts:
- host: chart-example.local
paths:
- path: /
pathType: ImplementationSpecific
tls: []
# - secretName: chart-example-tls
# hosts:
# - chart-example.local
name: ""
resources: {}
# We usually recommend not to specify default resources and to leave this as a conscious
# choice for the user. This also increases chances charts run on environments with little
# resources, such as Minikube. If you do want to specify resources, uncomment the following
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
service:
type: ClusterIP
port: 30000
targetPort: 30000
env:
PUID: 1027
PGID: 100
PAPERLESS_AI_PORT: 30000
# Konfiguration für persistente Speicherung (Persistent Volume Claim).
persistence:
enabled: true
storageClassName: ""
accessMode: ReadWriteOnce
size: 1Gi
# Sicherheitskontext-Einstellungen für Pod und Container.
securityContext:
enabled: true
pod:
runAsUser: 1027
runAsGroup: 100
fsGroup: 100
container:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
# Konfiguration für Horizontal Pod Autoscaling (HPA).
autoscaling:
enabled: false
minReplicas: 1
maxReplicas: 10
targetCPUUtilizationPercentage: 80
# Ressourcenanforderungen und -limits für den Container.
resources:
{}
# Wir empfehlen in der Regel, keine Standardressourcen anzugeben und dies
# dem Benutzer zu überlassen. Dies erhöht auch die Chancen, dass Charts
# in Umgebungen mit geringen Ressourcen, wie Minikube, laufen.
# Wenn du Ressourcen angeben möchtest, kommentiere die folgenden Zeilen aus,
# passe sie bei Bedarf an und entferne die geschweiften Klammern nach 'resources:'.
# limits:
# cpu: 100m
# memory: 128Mi
@ -75,78 +62,26 @@ resources: {}
# cpu: 100m
# memory: 128Mi
# This is to setup the liveness and readiness probes more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/
livenessProbe:
initialDelaySeconds: 90
httpGet:
path: /
# path: /health
port: http
readinessProbe:
initialDelaySeconds: 90
httpGet:
path: /
# path: /health
port: http
# paperless-ai config
paperless:
apiUrl: "http://paperless-ngx:8000"
apiToken:
ai:
provider: "openai"
addProcessedTag: yes
processedTagName: ai-processed
prompt:
useTags: yes
tags: Rechnung,Kontoauszug,Vertrag,Arbeitgeber
openAi:
apiKey:
model: "gpt-4o-mini"
ollama:
apiUrl: ""
model: ""
scanInterval: "*/30 * * * *"
systemPrompt: |-
Return the result EXCLUSIVELY as a JSON object. The Tags and Title MUST be in the language that is used in the document.:
{
"title": "xxxxx",
"correspondent": "xxxxxxxx",
"tags": ["Tag1", "Tag2", "Tag3", "Tag4"],
"document_date": "YYYY-MM-DD",
"language": "en/de/es/..."
}
processPredefinedDocuments: "no"
tags: "indexed,indexed2"
# additional envs, if neccessary
envs: []
# - name: CONFIG_PATH
# value: "/app/config"
# Node-Selector für die Pod-Platzierung.
nodeSelector: {}
# Toleranzen für die Pod-Platzierung auf Tainted Nodes.
tolerations: []
# Affinitätsregeln für die Pod-Platzierung.
affinity: {}
# persistence volumes needed for configuration and processing data directory
persistence:
config:
mountPath: "/app/config/config.js"
subPath: "config.js"
envfile:
mountPath: "app/.env"
subPath: ".env"
data:
enabled: true
size: 1Gi
storageClass: standard
mountPath: "/app/data"
# Ingress-Konfiguration (optional, aber üblich für Webanwendungen).
ingress:
enabled: false
className: "" # Der Ingress-Klassenname (z.B. nginx, traefik).
annotations: {}
hosts:
- host: chart-example.local # Beispiel-Hostname.
paths:
- path: / # Der Pfad, der weitergeleitet werden soll.
pathType: ImplementationSpecific # Der Typ des Pfades (Prefix, Exact, ImplementationSpecific).
tls: [] # TLS-Konfiguration für den Ingress.
# - secretName: chart-example-tls # Name des Secrets, das das TLS-Zertifikat enthält.
# hosts:
# - chart-example.local # Hostnamen, für die das Zertifikat gültig ist.