2023-11-20 20:14:33 -08:00
|
|
|
# Docker Compose file for running paperless from the Docker Hub.
|
2021-04-11 15:16:04 +02:00
|
|
|
# This file contains everything paperless needs to run.
|
|
|
|
|
# Paperless supports amd64, arm and arm64 hardware.
|
|
|
|
|
#
|
|
|
|
|
# All compose files of paperless configure paperless in the following way:
|
|
|
|
|
#
|
|
|
|
|
# - Paperless is (re)started on system boot, if it was running before shutdown.
|
|
|
|
|
# - Docker volumes for storing data are managed by Docker.
|
|
|
|
|
# - Folders for importing and exporting files are created in the same directory
|
|
|
|
|
# as this file and mounted to the correct folders inside the container.
|
|
|
|
|
# - Paperless listens on port 8010.
|
|
|
|
|
#
|
2023-11-20 20:14:33 -08:00
|
|
|
# In addition to that, this Docker Compose file adds the following optional
|
2021-04-11 15:16:04 +02:00
|
|
|
# configurations:
|
|
|
|
|
#
|
|
|
|
|
# - Instead of SQLite (default), PostgreSQL is used as the database server.
|
|
|
|
|
#
|
|
|
|
|
# To install and update paperless with this file, do the following:
|
|
|
|
|
#
|
|
|
|
|
# - Open portainer Stacks list and click 'Add stack'
|
2024-01-21 19:34:04 +01:00
|
|
|
# - Paste the contents of this file and assign a name, e.g. 'paperless'
|
2024-11-16 05:19:18 +01:00
|
|
|
# - Upload 'docker-compose.env' by clicking on 'Load variables from .env file'
|
|
|
|
|
# - Modify the environment variables as needed
|
2021-04-11 15:16:04 +02:00
|
|
|
# - Click 'Deploy the stack' and wait for it to be deployed
|
|
|
|
|
#
|
|
|
|
|
# For more extensive installation and update instructions, refer to the
|
|
|
|
|
# documentation.
|
|
|
|
|
services:
|
|
|
|
|
broker:
|
2025-05-07 16:49:18 +00:00
|
|
|
image: docker.io/library/redis:8
|
2021-04-11 15:16:04 +02:00
|
|
|
restart: unless-stopped
|
2022-02-22 10:01:09 -08:00
|
|
|
volumes:
|
|
|
|
|
- redisdata:/data
|
2021-04-11 15:16:04 +02:00
|
|
|
db:
|
2025-09-30 20:25:02 +00:00
|
|
|
image: docker.io/library/postgres:18
|
2021-04-11 15:16:04 +02:00
|
|
|
restart: unless-stopped
|
|
|
|
|
volumes:
|
|
|
|
|
- pgdata:/var/lib/postgresql/data
|
|
|
|
|
environment:
|
|
|
|
|
POSTGRES_DB: paperless
|
|
|
|
|
POSTGRES_USER: paperless
|
|
|
|
|
POSTGRES_PASSWORD: paperless
|
|
|
|
|
webserver:
|
2022-02-20 09:23:18 +01:00
|
|
|
image: ghcr.io/paperless-ngx/paperless-ngx:latest
|
2021-04-11 15:16:04 +02:00
|
|
|
restart: unless-stopped
|
|
|
|
|
depends_on:
|
|
|
|
|
- db
|
|
|
|
|
- broker
|
|
|
|
|
ports:
|
2023-02-09 02:25:25 -05:00
|
|
|
- "8010:8000"
|
2021-04-11 15:16:04 +02:00
|
|
|
volumes:
|
|
|
|
|
- data:/usr/src/paperless/data
|
|
|
|
|
- media:/usr/src/paperless/media
|
|
|
|
|
- ./export:/usr/src/paperless/export
|
|
|
|
|
- ./consume:/usr/src/paperless/consume
|
|
|
|
|
environment:
|
|
|
|
|
PAPERLESS_REDIS: redis://broker:6379
|
|
|
|
|
PAPERLESS_DBHOST: db
|
2024-11-16 05:19:18 +01:00
|
|
|
env_file:
|
|
|
|
|
- stack.env
|
2021-04-11 15:16:04 +02:00
|
|
|
volumes:
|
|
|
|
|
data:
|
|
|
|
|
media:
|
|
|
|
|
pgdata:
|
2022-02-22 10:01:09 -08:00
|
|
|
redisdata:
|