GabrieVanZanten

compose

Aug 31st, 2025
245
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 3.07 KB | None | 0 0
  1. # Docker Compose file for running paperless from the Docker Hub.
  2. # This file contains everything paperless needs to run.
  3. # Paperless supports amd64, arm and arm64 hardware.
  4. #
  5. # All compose files of paperless configure paperless in the following way:
  6. #
  7. # - Paperless is (re)started on system boot, if it was running before shutdown.
  8. # - Docker volumes for storing data are managed by Docker.
  9. # - Folders for importing and exporting files are created in the same directory
  10. #   as this file and mounted to the correct folders inside the container.
  11. # - Paperless listens on port 8000.
  12. #
  13. # In addition to that, this Docker Compose file adds the following optional
  14. # configurations:
  15. #
  16. # - Instead of SQLite (default), MariaDB is used as the database server.
  17. #
  18. # To install and update paperless with this file, do the following:
  19. #
  20. # - Copy this file as 'docker-compose.yml' and the files 'docker-compose.env'
  21. #   and '.env' into a folder.
  22. # - Run 'docker compose pull'.
  23. # - Run 'docker compose up -d'.
  24. #
  25. # For more extensive installation and update instructions, refer to the
  26. # documentation.
  27.  
  28. services:
  29.   broker:
  30.     image: docker.io/library/redis:8
  31.     restart: unless-stopped
  32.     volumes:
  33.      - /var/paperless/redisdata:/data
  34.   db:
  35.     image: docker.io/library/mariadb:11
  36.     restart: unless-stopped
  37.     volumes:
  38.      - /var/paperless/dbdata:/var/lib/mysql
  39.     environment:
  40.       MARIADB_HOST: paperless
  41.       MARIADB_DATABASE: paperless
  42.       MARIADB_USER: paperless
  43.       MARIADB_PASSWORD: paperless
  44.       MARIADB_ROOT_PASSWORD: paperless
  45.   webserver:
  46.     image: ghcr.io/paperless-ngx/paperless-ngx:latest
  47.     restart: unless-stopped
  48.     depends_on:
  49.      - db
  50.       - broker
  51.       - gotenberg
  52.       - tika
  53.     ports:
  54.      - "8000:8000"
  55.     volumes:
  56.      - /var/paperless/data:/usr/src/paperless/data
  57.       - /var/paperless/media:/usr/src/paperless/media
  58.       - /var/paperless/export:/usr/src/paperless/export
  59.       - /var/paperless/consume:/usr/src/paperless/consume
  60.     env_file: docker-compose.env
  61.     environment:
  62.       PAPERLESS_REDIS: redis://broker:6379
  63.       PAPERLESS_DBENGINE: mariadb
  64.       PAPERLESS_DBHOST: db
  65.       PAPERLESS_DBUSER: paperless # only needed if non-default username
  66.       PAPERLESS_DBPASS: paperless # only needed if non-default password
  67.       PAPERLESS_DBPORT: 3306
  68.       PAPERLESS_TIKA_ENABLED: 1
  69.       PAPERLESS_TIKA_GOTENBERG_ENDPOINT: http://gotenberg:3000
  70.       PAPERLESS_TIKA_ENDPOINT: http://tika:9998
  71.       PAPERLESS_SECRET_KEY: azhkhgozwYfD2brPyTrjQstwLVVHcp
  72.       PAPERLESS_ALLOWED_HOSTS: "paperless.vanzanten.be,paperless.intern.vanzanten.be,papertest.intern.vanzanten.be"
  73.  
  74.   gotenberg:
  75.     image: docker.io/gotenberg/gotenberg:8.20
  76.     restart: unless-stopped
  77.     # The gotenberg chromium route is used to convert .eml files. We do not
  78.     # want to allow external content like tracking pixels or even javascript.
  79.     command:
  80.      - "gotenberg"
  81.       - "--chromium-disable-javascript=true"
  82.       - "--chromium-allow-list=file:///tmp/.*"
  83.   tika:
  84.     image: docker.io/apache/tika:latest
  85.     restart: unless-stopped
Advertisement
Add Comment
Please, Sign In to add comment