Advertisement
SRoy

docker-compose.yaml

May 26th, 2022
654
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. version: '3'
  2. services:
  3.   photoprismsroy:
  4.    ## Use photoprism/photoprism:preview-arm64 for testing preview builds:
  5.     image: photoprism/photoprism:arm64
  6.     depends_on:
  7.      - mariadbsroy
  8.     ## Don't enable automatic restarts until PhotoPrism has been properly configured and tested!
  9.     ## If the service gets stuck in a restart loop, this points to a memory, filesystem, network, or database issue:
  10.     ## https://docs.photoprism.app/getting-started/troubleshooting/#fatal-server-errors
  11.     restart: unless-stopped
  12.     security_opt:
  13.      - seccomp:unconfined
  14.       - apparmor:unconfined
  15.     ports:
  16.      - "2345:2345" # HTTP port (host:container)
  17.     environment:
  18.       PHOTOPRISM_ADMIN_PASSWORD: "censoredpass"          # !!! PLEASE CHANGE YOUR INITIAL "admin" PASSWORD !!!
  19.       PHOTOPRISM_SITE_URL: "http://localhost:2345/"  # public server URL incl http:// or https:// and /path, :port is optional
  20.       PHOTOPRISM_ORIGINALS_LIMIT: 5000               # file size limit for originals in MB (increase for high-res video)
  21.       PHOTOPRISM_HTTP_COMPRESSION: "gzip"            # improves transfer speed and bandwidth utilization (none or gzip)
  22.       PHOTOPRISM_WORKERS: 2                          # limits the number of indexing workers to reduce system load
  23.       PHOTOPRISM_DEBUG: "false"                      # run in debug mode (shows additional log messages)
  24.       PHOTOPRISM_PUBLIC: "false"                     # no authentication required (disables password protection)
  25.       PHOTOPRISM_READONLY: "false"                   # don't modify originals directory (reduced functionality)
  26.       PHOTOPRISM_EXPERIMENTAL: "false"               # enables experimental features
  27.       PHOTOPRISM_DISABLE_CHOWN: "false"              # disables storage permission updates on startup
  28.       PHOTOPRISM_DISABLE_WEBDAV: "false"             # disables built-in WebDAV server
  29.       PHOTOPRISM_DISABLE_SETTINGS: "false"           # disables Settings in Web UI
  30.       PHOTOPRISM_DISABLE_TENSORFLOW: "false"         # disables all features depending on TensorFlow
  31.       PHOTOPRISM_DISABLE_FACES: "false"              # disables facial recognition
  32.       PHOTOPRISM_DISABLE_CLASSIFICATION: "false"     # disables image classification
  33.       PHOTOPRISM_DARKTABLE_PRESETS: "true"           # enables Darktable presets and disables concurrent RAW conversion
  34.       # PHOTOPRISM_FFMPEG_ENCODER: "h264_v4l2m2m"    # FFmpeg AVC encoder for video transcoding (default: libx264)
  35.       # PHOTOPRISM_FFMPEG_BUFFERS: "64"              # FFmpeg capture buffers (default: 32)
  36.       PHOTOPRISM_DETECT_NSFW: "true"                # flag photos as private that MAY be offensive
  37.       PHOTOPRISM_UPLOAD_NSFW: "true"                 # allow uploads that MAY be offensive
  38.       # PHOTOPRISM_DATABASE_DRIVER: "sqlite"         # SQLite is an embedded database that doesn't require a server
  39.       PHOTOPRISM_DATABASE_DRIVER: "mysql"            # use MariaDB 10.5+ or MySQL 8+ instead of SQLite for improved performance
  40.       PHOTOPRISM_DATABASE_SERVER: "mariadb:3305"     # MariaDB or MySQL database server (hostname:port)
  41.       PHOTOPRISM_DATABASE_NAME: "photoprism"         # MariaDB or MySQL database schema name
  42.       PHOTOPRISM_DATABASE_USER: "photoprism"         # MariaDB or MySQL database user name
  43.       PHOTOPRISM_DATABASE_PASSWORD: "censoredpass"       # MariaDB or MySQL database user password
  44.       PHOTOPRISM_SITE_TITLE: "PhotoPrism"
  45.       PHOTOPRISM_SITE_CAPTION: "AI-Powered Photos App"
  46.       PHOTOPRISM_SITE_DESCRIPTION: ""
  47.       PHOTOPRISM_SITE_AUTHOR: "Roy"
  48.       ## Run/install on first startup (options: update, gpu, tensorflow, davfs, clean):
  49.       # PHOTOPRISM_INIT: "update clean"
  50.       ## Run as a specific user, group, or with a custom umask (does not work together with "user:")
  51.       # PHOTOPRISM_UID: 1000
  52.       # PHOTOPRISM_GID: 1000
  53.       # PHOTOPRISM_UMASK: 0000
  54.       HOME: "/mnt/Sandisk1TB/photoprism/sroy"
  55.     ## Start as a non-root user (see https://docs.docker.com/engine/reference/run/#user)
  56.     # user: "1000:1000"
  57.     ## Share hardware devices with FFmpeg and TensorFlow (optional):
  58.     # devices:
  59.     #  - "/dev/video11:/dev/video11" # Video4Linux (h264_v4l2m2m)
  60.     working_dir: "/mnt/Sandisk1TB/photoprism/sroy"
  61.     ## Storage Folders: "~" is a shortcut for your home directory, "." for the current directory
  62.     volumes:
  63.      # "/host/folder:/photoprism/folder"                # example
  64.       - "/mnt/Sandisk1TB/photoprism/sroy/Pictures:/photoprism/originals"               # original media files (photos and videos)
  65.       # - "/example/family:/photoprism/originals/family" # *additional* media folders can be mounted like this
  66.       - "/mnt/Sandisk1TB/photoprism/sroy/Import:/photoprism/import"                  # *optional* base folder from which files can be imported to originals
  67.       - "/mnt/Sandisk1TB/photoprism/sroy/storage:/photoprism/storage"                  # *writable* storage folder for cache, database, and sidecar files (never remove)
  68.  
  69.     ## Database Server (recommended)
  70.     ## see https://docs.photoprism.app/getting-started/faq/#should-i-use-sqlite-mariadb-or-mysql
  71.   mariadbsroy:
  72.    ## If MariaDB gets stuck in a restart loop, this points to a memory or filesystem issue:
  73.     ## https://docs.photoprism.app/getting-started/troubleshooting/#fatal-server-errors
  74.     restart: unless-stopped
  75.     image: arm64v8/mariadb:10.6 # this mariadb image runs on ARM64-based devices only
  76.     security_opt:
  77.      - seccomp:unconfined
  78.       - apparmor:unconfined
  79.     ports:
  80.      - "3305:3305"
  81.     command: mysqld --innodb-buffer-pool-size=128M --transaction-isolation=READ-COMMITTED --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci --max-connections=512 --innodb-rollback-on-timeout=OFF --innodb-lock-wait-timeout=120
  82.     ## Never store database files on an unreliable device such as a USB flash drive, an SD card, or a shared network folder:
  83.     volumes:
  84.      - "/mnt/Sandisk1TB/photoprism/sroy/database:/var/lib/mysql" # important, don't remove
  85.     environment:
  86.       MYSQL_ROOT_PASSWORD: censoredpass
  87.       MYSQL_DATABASE: photoprism
  88.       MYSQL_USER: photoprism
  89.       MYSQL_PASSWORD: censoredpass
  90.      
  91.      
  92.   photoprismcroy:
  93.    ## Use photoprism/photoprism:preview-arm64 for testing preview builds:
  94.     image: photoprism/photoprism:arm64
  95.     depends_on:
  96.      - mariadbcroy
  97.     ## Don't enable automatic restarts until PhotoPrism has been properly configured and tested!
  98.     ## If the service gets stuck in a restart loop, this points to a memory, filesystem, network, or database issue:
  99.     ## https://docs.photoprism.app/getting-started/troubleshooting/#fatal-server-errors
  100.     restart: unless-stopped
  101.     security_opt:
  102.      - seccomp:unconfined
  103.       - apparmor:unconfined
  104.     ports:
  105.      - "2346:2346" # HTTP port (host:container)
  106.     environment:
  107.       PHOTOPRISM_ADMIN_PASSWORD: "censoredpass"          # !!! PLEASE CHANGE YOUR INITIAL "admin" PASSWORD !!!
  108.       PHOTOPRISM_SITE_URL: "http://localhost:2346/"  # public server URL incl http:// or https:// and /path, :port is optional
  109.       PHOTOPRISM_ORIGINALS_LIMIT: 5000               # file size limit for originals in MB (increase for high-res video)
  110.       PHOTOPRISM_HTTP_COMPRESSION: "gzip"            # improves transfer speed and bandwidth utilization (none or gzip)
  111.       PHOTOPRISM_WORKERS: 2                          # limits the number of indexing workers to reduce system load
  112.       PHOTOPRISM_DEBUG: "false"                      # run in debug mode (shows additional log messages)
  113.       PHOTOPRISM_PUBLIC: "false"                     # no authentication required (disables password protection)
  114.       PHOTOPRISM_READONLY: "false"                   # don't modify originals directory (reduced functionality)
  115.       PHOTOPRISM_EXPERIMENTAL: "false"               # enables experimental features
  116.       PHOTOPRISM_DISABLE_CHOWN: "false"              # disables storage permission updates on startup
  117.       PHOTOPRISM_DISABLE_WEBDAV: "false"             # disables built-in WebDAV server
  118.       PHOTOPRISM_DISABLE_SETTINGS: "false"           # disables Settings in Web UI
  119.       PHOTOPRISM_DISABLE_TENSORFLOW: "false"         # disables all features depending on TensorFlow
  120.       PHOTOPRISM_DISABLE_FACES: "false"              # disables facial recognition
  121.       PHOTOPRISM_DISABLE_CLASSIFICATION: "false"     # disables image classification
  122.       PHOTOPRISM_DARKTABLE_PRESETS: "true"           # enables Darktable presets and disables concurrent RAW conversion
  123.       # PHOTOPRISM_FFMPEG_ENCODER: "h264_v4l2m2m"    # FFmpeg AVC encoder for video transcoding (default: libx264)
  124.       # PHOTOPRISM_FFMPEG_BUFFERS: "64"              # FFmpeg capture buffers (default: 32)
  125.       PHOTOPRISM_DETECT_NSFW: "true"                # flag photos as private that MAY be offensive
  126.       PHOTOPRISM_UPLOAD_NSFW: "true"                 # allow uploads that MAY be offensive
  127.       # PHOTOPRISM_DATABASE_DRIVER: "sqlite"         # SQLite is an embedded database that doesn't require a server
  128.       PHOTOPRISM_DATABASE_DRIVER: "mysql"            # use MariaDB 10.5+ or MySQL 8+ instead of SQLite for improved performance
  129.       PHOTOPRISM_DATABASE_SERVER: "mariadb:3306"     # MariaDB or MySQL database server (hostname:port)
  130.       PHOTOPRISM_DATABASE_NAME: "photoprism"         # MariaDB or MySQL database schema name
  131.       PHOTOPRISM_DATABASE_USER: "photoprism"         # MariaDB or MySQL database user name
  132.       PHOTOPRISM_DATABASE_PASSWORD: "censoredpass"       # MariaDB or MySQL database user password
  133.       PHOTOPRISM_SITE_TITLE: "PhotoPrism"
  134.       PHOTOPRISM_SITE_CAPTION: "AI-Powered Photos App"
  135.       PHOTOPRISM_SITE_DESCRIPTION: ""
  136.       PHOTOPRISM_SITE_AUTHOR: "Roy"
  137.       ## Run/install on first startup (options: update, gpu, tensorflow, davfs, clean):
  138.       # PHOTOPRISM_INIT: "update clean"
  139.       ## Run as a specific user, group, or with a custom umask (does not work together with "user:")
  140.       # PHOTOPRISM_UID: 1000
  141.       # PHOTOPRISM_GID: 1000
  142.       # PHOTOPRISM_UMASK: 0000
  143.       HOME: "/mnt/Sandisk1TB/photoprism/croy"
  144.     ## Start as a non-root user (see https://docs.docker.com/engine/reference/run/#user)
  145.     # user: "1000:1000"
  146.     ## Share hardware devices with FFmpeg and TensorFlow (optional):
  147.     # devices:
  148.     #  - "/dev/video11:/dev/video11" # Video4Linux (h264_v4l2m2m)
  149.     working_dir: "/mnt/Sandisk1TB/photoprism/croy"
  150.     ## Storage Folders: "~" is a shortcut for your home directory, "." for the current directory
  151.     volumes:
  152.      # "/host/folder:/photoprism/folder"                # example
  153.       - "/mnt/Sandisk1TB/photoprism/croy/Pictures:/photoprism/originals"               # original media files (photos and videos)
  154.       # - "/example/family:/photoprism/originals/family" # *additional* media folders can be mounted like this
  155.       - "/mnt/Sandisk1TB/photoprism/croy/Import:/photoprism/import"                  # *optional* base folder from which files can be imported to originals
  156.       - "/mnt/Sandisk1TB/photoprism/croy/storage:/photoprism/storage"                  # *writable* storage folder for cache, database, and sidecar files (never remove)
  157.  
  158.     ## Database Server (recommended)
  159.     ## see https://docs.photoprism.app/getting-started/faq/#should-i-use-sqlite-mariadb-or-mysql
  160.   mariadbcroy:
  161.    ## If MariaDB gets stuck in a restart loop, this points to a memory or filesystem issue:
  162.     ## https://docs.photoprism.app/getting-started/troubleshooting/#fatal-server-errors
  163.     restart: unless-stopped
  164.     image: arm64v8/mariadb:10.6 # this mariadb image runs on ARM64-based devices only
  165.     security_opt:
  166.      - seccomp:unconfined
  167.       - apparmor:unconfined
  168.     ports:
  169.      - "3306:3306"
  170.     command: mysqld --innodb-buffer-pool-size=128M --transaction-isolation=READ-COMMITTED --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci --max-connections=512 --innodb-rollback-on-timeout=OFF --innodb-lock-wait-timeout=120
  171.     ## Never store database files on an unreliable device such as a USB flash drive, an SD card, or a shared network folder:
  172.     volumes:
  173.      - "/mnt/Sandisk1TB/photoprism/croy/database:/var/lib/mysql" # important, don't remove
  174.     environment:
  175.       MYSQL_ROOT_PASSWORD: censoredpass
  176.       MYSQL_DATABASE: photoprism
  177.       MYSQL_USER: photoprism
  178.       MYSQL_PASSWORD: censoredpass
Advertisement
RAW Paste Data Copied
Advertisement