feat: Add paperless
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
---
|
||||
- name: Create directory for docker-compose
|
||||
ansible.builtin.file:
|
||||
path: /root/docker/
|
||||
state: directory
|
||||
mode: "0755"
|
||||
|
||||
- name: Copy docker-compose file
|
||||
template:
|
||||
src: "docker-compose.yml"
|
||||
dest: /root/docker/docker-compose.yml
|
||||
owner: root
|
||||
group: root
|
||||
mode: 0755
|
||||
|
||||
- name: Run docker-compose
|
||||
ansible.builtin.shell:
|
||||
args:
|
||||
cmd: docker compose up -d
|
||||
chdir: /root/docker/
|
||||
@@ -0,0 +1,57 @@
|
||||
version: "3.4"
|
||||
|
||||
services:
|
||||
broker:
|
||||
image: redis:6.0
|
||||
container_name: paperless-broker
|
||||
restart: unless-stopped
|
||||
|
||||
db:
|
||||
image: postgres:13
|
||||
container_name: paperless-db
|
||||
restart: unless-stopped
|
||||
volumes:
|
||||
- /data/paperless/db:/var/lib/postgresql/data
|
||||
environment:
|
||||
POSTGRES_DB: paperless
|
||||
POSTGRES_USER: paperless
|
||||
POSTGRES_PASSWORD: paperless
|
||||
|
||||
webserver:
|
||||
image: ghcr.io/paperless-ngx/paperless-ngx:latest
|
||||
container_name: paperless-app
|
||||
restart: unless-stopped
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost:8000"]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 5
|
||||
ports:
|
||||
- 8003:8000
|
||||
volumes:
|
||||
- /data/paperless/data:/usr/src/paperless/data
|
||||
- /data/paperless/media:/usr/src/paperless/media
|
||||
- /data/paperless/export:/usr/src/paperless/export
|
||||
- /data/paperless/consume:/usr/src/paperless/consume
|
||||
environment:
|
||||
PAPERLESS_URL: https://paperless.lino.cooking
|
||||
PAPERLESS_REDIS: redis://paperless-broker:6379
|
||||
PAPERLESS_DBHOST: paperless-db
|
||||
# The UID and GID of the user used to run paperless in the container. Set this
|
||||
# to your UID and GID on the host so that you have write access to the
|
||||
# consumption directory.
|
||||
USERMAP_UID: 0
|
||||
USERMAP_GID: 0
|
||||
# Additional languages to install for text recognition, separated by a
|
||||
# whitespace. Note that this is
|
||||
# different from PAPERLESS_OCR_LANGUAGE (default=eng), which defines the
|
||||
# language used for OCR.
|
||||
# The container installs English, German, Italian, Spanish and French by
|
||||
# default.
|
||||
# See https://packages.debian.org/search?keywords=tesseract-ocr-&searchon=names&suite=buster
|
||||
# for available languages.
|
||||
PAPERLESS_OCR_LANGUAGES: eng por
|
||||
# Adjust this key if you plan to make paperless available publicly. It should
|
||||
# be a very long sequence of random characters. You don't need to remember it.
|
||||
PAPERLESS_SECRET_KEY: '{{ paperless_pwd }}'
|
||||
PAPERLESS_TIME_ZONE: Europe/Lisbon
|
||||
Reference in New Issue
Block a user