From 6f8f9618d1640b04ac3837750dd575b03d916fd5 Mon Sep 17 00:00:00 2001 From: Gabriel Augendre Date: Sun, 8 Dec 2024 16:55:33 +0100 Subject: [PATCH] move paperless folders from volumes to local folders --- playbooks/apps/files/bin/restic-excludes | 2 ++ .../apps/files/paperless-ngx/docker-compose.yaml | 6 ++---- playbooks/apps/paperless-ngx.yaml | 16 ++++++++++++++++ .../paperless-ngx/docker-compose.env.j2 | 6 ++++++ 4 files changed, 26 insertions(+), 4 deletions(-) diff --git a/playbooks/apps/files/bin/restic-excludes b/playbooks/apps/files/bin/restic-excludes index 3f63434..ca453c2 100644 --- a/playbooks/apps/files/bin/restic-excludes +++ b/playbooks/apps/files/bin/restic-excludes @@ -28,3 +28,5 @@ whisper-data # ghost versions versions backups/hass +paperless/data +paperless/media diff --git a/playbooks/apps/files/paperless-ngx/docker-compose.yaml b/playbooks/apps/files/paperless-ngx/docker-compose.yaml index 5aa5e2c..8c3e662 100644 --- a/playbooks/apps/files/paperless-ngx/docker-compose.yaml +++ b/playbooks/apps/files/paperless-ngx/docker-compose.yaml @@ -58,8 +58,8 @@ services: ports: - "127.0.0.1:8014:8000" volumes: - - data:/usr/src/paperless/data - - media:/usr/src/paperless/media + - ./data:/usr/src/paperless/data + - ./media:/usr/src/paperless/media - ./export:/usr/src/paperless/export - ./consume:/usr/src/paperless/consume env_file: docker-compose.env @@ -102,7 +102,5 @@ services: - './consume:/home/ftpuser' volumes: - data: - media: pgdata: redisdata: diff --git a/playbooks/apps/paperless-ngx.yaml b/playbooks/apps/paperless-ngx.yaml index 8b08197..442ab1a 100644 --- a/playbooks/apps/paperless-ngx.yaml +++ b/playbooks/apps/paperless-ngx.yaml @@ -25,3 +25,19 @@ 30333564313630346661333931623266313465333665343930383438353961376437343637646364 6532666134663636660a656537363262646437366135353661656264356337643039363439353731 3930 + email_user: !vault | + $ANSIBLE_VAULT;1.1;AES256 + 66323263336336343862353363636530613238383532643262393865323930633438643236333961 + 6339313664336237643935666337353064376364306637640a366232613231623463633364333533 + 39643030356238313165363231313465663232633962613961646266376430323832366639333636 + 3335663032656232390a393236666534343738663333376164333730326637373239383461663337 + 37613433343133323331633462396333343062323438373766653834346466343766 + email_password: !vault | + $ANSIBLE_VAULT;1.1;AES256 + 30363431643330643364633736383331383630353263353637653931336465656336366566353735 + 3231366230626466376138316561306665316565313731380a303066356637303763343536646461 + 30616365616561353865333838326534623232626164333261643064333434356531393236333737 + 6238646361353837630a663763653638393833613565393332363735626533356236393334353032 + 34373039666464333139363136373561623662653839343435613861333335633339636131633530 + 61353563646332306536346431336331393531363065316136633837313465363934353763316664 + 393461396163306265613134363634653032 diff --git a/playbooks/apps/templates/paperless-ngx/docker-compose.env.j2 b/playbooks/apps/templates/paperless-ngx/docker-compose.env.j2 index b707c72..9635d8d 100644 --- a/playbooks/apps/templates/paperless-ngx/docker-compose.env.j2 +++ b/playbooks/apps/templates/paperless-ngx/docker-compose.env.j2 @@ -50,3 +50,9 @@ PAPERLESS_TASK_WORKERS=2 PAPERLESS_OCR_USER_ARGS={"invalidate_digital_signatures": true} PAPERLESS_FILENAME_FORMAT={{ '{{' }} created_year }}/{{ '{{' }} correspondent }}/{{ '{{' }} title }} + +PAPERLESS_EMAIL_HOST=smtp.mailgun.org +PAPERLESS_EMAIL_PORT=587 +PAPERLESS_EMAIL_USE_TLS=true +PAPERLESS_EMAIL_HOST_USER={{ email_user }} +PAPERLESS_EMAIL_HOST_PASSWORD={{ email_password }}