paperless: Add restic backups

This commit is contained in:
Marty Oehme 2025-07-18 16:56:08 +02:00
parent e13d85990c
commit b81328d400
Signed by: Marty
GPG key ID: 4E535BC19C61886E
2 changed files with 21 additions and 0 deletions

View file

@ -65,6 +65,24 @@ services:
environment:
REDIS_ARGS: "--save 60 10"
{% if restic_enable is not undefined and not false and stack_paperless_restic_enable is not undefined and not false %}
backup:
image: mazzolino/restic
environment:
TZ: "{{ restic_tz }}"
BACKUP_CRON: "{{ stack_paperless_restic_cron }}"
RESTIC_REPOSITORY: "{{ restic_repo }}"
RESTIC_PASSWORD: "{{ restic_pass }}"
AWS_ACCESS_KEY_ID: "{{ restic_s3_key }}"
AWS_SECRET_ACCESS_KEY: "{{ restic_s3_secret }}"
RESTIC_BACKUP_ARGS: >-
--tag paperless
RESTIC_BACKUP_SOURCES: "/backup"
volumes:
- "{{ stack_paperless_env_dir }}:/backup/{{ stack_paperless_env_dir }}"
- "{{ stack_paperless_serve_dir }}/documents:/backup/{{ stack_paperless_serve_dir }}/documents"
{% endif %}
networks:
caddy:
external: true