Ansible role to install and configure paperless.
A python3 and nginx installation are required. We recommend using pyslackers.python and pyslackers.nginx.
To install this roles clone it into your roles directory.
$ git clone https://github.com/ovv/ansible-role-paperless.git ovv.paperless
If your playbook already reside inside a git repository you can clone it by using git submodules.
$ git submodule add -b master https://github.com/ovv/ansible-role-paperless.git ovv.paperless
-
paperless_admin_user
: Paperless admin user. -
paperless_admin_email
: Paperless admin email. -
paperless_admin_password
: Paperless admin password. -
paperless_encrypt_passphrase
: Paperless encryption passphrase. -
paperless_secret_key
: Paperless secret key. -
paperless_consumption_dir
: Consumption directory for paperless (default to/opt/paperless/consumption
). -
paperless_consumption_dir_group
: Group of the consumption directory (default topaperless
). -
paperless_consumption_dir_users
: List of users to add to thepaperless_consumption_dir_group
(default to[]
). -
paperless_consumption_dir_mode
: Consumption directory mode (default to0770
). -
paperless_list_per_page
: Number of item per page (default to100
). -
paperless_tz
: Timezone (default toEtc/UTC
). -
paperless_ocr_language
: Default ocr language (default toeng
). -
paperless_force_script_name
: See paperless configuration file. (default toFalse
). -
paperless_disable_login
: Disable user authentication (default toFalse
). -
paperless_inline_doc
: Allow viewing document in browser (default toFalse
). -
paperless_allowed_host
: List of hosts allowed to connect (default to[127.0.0.1, localhost]
). -
paperless_custom_packages
: Custom packages to install, like some tesseract languages (default to[]
). -
paperless_backup
: Export paperless documents and fetch them topaperless_backup_directory
(default toFalse
). -
paperless_restore
: Upload and import documents from thepaperless_backup_directory
(default toFalse
). -
paperless_backup_directory
: Directory on the computer launching the ansible where to store documents backup.
Other variable and their defaults are located in defaults.
- hosts: paperless
tags:
- paperless
roles:
- pyslackers.python
- ovv.paperless
- pyslackers.nginx
vars:
paperless_admin_user: admin
paperless_admin_password: password
paperless_admin_email: [email protected]
paperless_encrypt_passphrase: passphrase
paperless_secret_key: supersecretkey
# pyslackers.python
virtualenvs:
paperless:
path: /opt/paperless/.env
version: 3.6.4
# pyslackers.nginx
nginx_sites:
paperless:
directory: /opt/paperless
locations:
- location: /static
custom: |
autoindex on;
alias /opt/paperless/static;
- location: /
proxy_pass: http://127.0.0.1:8000