111 lines
2.9 KiB
YAML
111 lines
2.9 KiB
YAML
---
|
|
|
|
paperless:
|
|
|
|
# Name of the instance (job and service name)
|
|
instance: paperless
|
|
|
|
# Connect to the postgres service through the mesh
|
|
consul:
|
|
connect:
|
|
upstreams:
|
|
- destination_name: postgres[[ .consul.suffix ]]
|
|
local_bind_port: 5432
|
|
|
|
# Env var to set in the containers
|
|
# The ones here will be inherited by all containers
|
|
env:
|
|
PAPERLESS_DBUSER: '{{ with secret "[[ .vault.prefix ]]database/creds/[[ .paperless.instance ]]" }}{{ .Data.username }}{{ end }}'
|
|
PAPERLESS_DBPASS: '{{ with secret "[[ .vault.prefix ]]database/creds/[[ .paperless.instance ]]" }}{{ .Data.password }}{{ end }}'
|
|
PAPERLESS_SECRET_KEY: '{{ with secret "[[ .vault.prefix ]]kv/service/[[ .paperless.instance ]]" }}{{ .Data.data.secret_key }}{{ end }}'
|
|
PAPERLESS_DBNAME: '[[ .paperless.instance ]]'
|
|
PAPERLESS_CORS_ALLOWED_HOSTS: '[[ .paperless.webserver.public_url ]]'
|
|
PAPERLESS_URL: '[[ .paperless.webserver.public_url ]]'
|
|
PAPERLESS_CONVERT_TMPDIR: /alloc/data
|
|
PAPERLESS_USE_X_FORWARD_HOST: true
|
|
PAPERLESS_PROXY_SSL_HEADER: "'[\"HTTP_X_FORWARDED_PROTO\", \"https\"]'"
|
|
PAPERLESS_ENABLE_COMPRESSION: false
|
|
PAPERLESS_TRUSTED_PROXIES: 127.0.0.1
|
|
|
|
# This is the main task
|
|
webserver:
|
|
|
|
# The Docker image to use
|
|
image: danielberteaud/paperless-ngx:1.17.4-1
|
|
|
|
# Env vars to set in the container
|
|
env: {}
|
|
|
|
# Resource allocation
|
|
resources:
|
|
cpu: 300
|
|
memory: 256
|
|
|
|
# The URL where BounCA will be available to users
|
|
public_url: https://paperless.example.org
|
|
|
|
# Traefik settings
|
|
traefik:
|
|
enabled: true
|
|
|
|
# The consumer will watch a folder (/input, where a volume is mounted) and
|
|
# import any files found.
|
|
consumer:
|
|
|
|
# You can disable the consumer if you do not use it, it'll save some resources
|
|
enabled: true
|
|
|
|
# The Docker image to use
|
|
image: '[[ .paperless.webserver.image ]]'
|
|
|
|
# Env vars to set in the container
|
|
env: {}
|
|
|
|
# Resource allocation
|
|
resources:
|
|
cpu: 100
|
|
memory: 150
|
|
|
|
# Task scheduler
|
|
scheduler:
|
|
|
|
# The Docker image to use
|
|
image: '[[ .paperless.webserver.image ]]'
|
|
|
|
# Env vars to set in the container
|
|
env: {}
|
|
|
|
# Resource allocation
|
|
resources:
|
|
cpu: 100
|
|
memory: 200
|
|
|
|
# The worker doing the document processing
|
|
task_queue:
|
|
|
|
# The Docker image to use
|
|
image: '[[ .paperless.webserver.image ]]'
|
|
|
|
# Env vars to set in the container
|
|
env: {}
|
|
|
|
# Resource allocation
|
|
resources:
|
|
cpu: 500
|
|
memory: 384
|
|
|
|
# Volumes for data persistance and exchange
|
|
volumes:
|
|
|
|
# This is the main volume where paperless keeps your documents
|
|
data:
|
|
type: csi
|
|
source: paperless-data
|
|
|
|
# This is a volume paperless will watch (with the consumer task) and
|
|
# any document found in it will be imported. If the consumer is disabled
|
|
# you can omit this volumes as it'll not be added to the job
|
|
input:
|
|
type: csi
|
|
source: paperless-input
|