====== Paperless NGX ======
**NOTE:** this is only a STUB to be completed in the future.
[[https://paperless-ngx.com|Paperless NGX]]
===== Installation =====
Paperless-NGX can be installed on bare-metal, but i find the container approach recomended.
So first of all, as usual, create the dedicated user:
useradd -d /data/daemons/paperless -m paperless
mkdir /data/paperless
chown paperless:paperless /data/paperless
and, as user **paperless**, create the **/data/daemons/paperless/docker-compose.yml** file:
network:
- paperless-net
networks:
paperless-net: {}
Adapt the paths and the port to your needs (8089).
Now pull it:
su - stirlingpdf
podman compose pull
===== Reverse Proxy =====
The following NGINX configuration file is the base for Stirling-PDF:
location /paperless/ {
proxy_pass http://127.0.0.1:xxxx;
access_log off;
client_max_body_size 200M;
proxy_read_timeout 3600;
}
Adapt the port to match the one in the docker compose. I also suggest to set a proper //client_max_body_size// to allow upload/download of big enough files, and also the //proxy_read_timeout// value.
See [[selfhost:nginx|The Reverse Proxy concept]]
===== Autostart =====
To start it, and set it up on boot, as usual follow my indications [[gentoo:containers|Using Containers on Gentoo]], so link the **user-containers** init script:
ln -s /etc/init.d/user-containers /etc/init.d/user-containers.paperless
and create the following config file:
USER=paperless
DESCRIPTION="The document manager"
Add the service to the default runlevel and start it now:
rc-update add user-containers.paperless default
rc-service user-containers.paperless start