Struggling with WebDAV Setup for PhotoPrism Behind NGINX Proxy Manager (Portainer: Docker)

134 Views Asked by At

I'm attempting to set up WebDAV for PhotoPrism behind an NGINX Proxy Manager but encountering difficulties. My setup includes:

  • PhotoPrism running in a Docker container, accessible at a subdomain photos.mydomain.com.
  • NGINX Proxy Manager (Version 2.10.4) also running in a Docker container, responsible for SSL/TLS certificates and proxying.
  • A root server with the IP XX.XX.XX.XX, hosting both services.

PhotoPrism is configured on port 2342; NGINX runs on ports 80 and 443. My goal is to synchronize photos from a QNAP NAS via WebDAV with PhotoPrism. However, I am encountering a "Method Not Allowed" error.

Here's my Docker stack for the NGINX Proxy Manager:

yaml

version: '3.8'
services:
  app:
    image: 'jc21/nginx-proxy-manager:latest'
    restart: unless-stopped
    ports:
      - '80:80'
      - '443:443'
      - '81:81'
    volumes:
      - ./data:/data
      - ./letsencrypt:/etc/letsencrypt

And here's my Docker stack for PhotoPrism:

yaml

version: '3.5'
services:
  photoprism:
    image: photoprism/photoprism:latest
    stop_grace_period: 10s
    depends_on:
      - mariadb
    security_opt:
      - seccomp:unconfined
      - apparmor:unconfined
    ports:
      - "2342:2342"
    environment:
      PHOTOPRISM_HTTP_PORT: 2342
      PHOTOPRISM_DATABASE_DRIVER: "mysql"
      PHOTOPRISM_DATABASE_SERVER: "mariadb:3306"
      PHOTOPRISM_DATABASE_NAME: "[Photoprism Databasename]"
      PHOTOPRISM_DATABASE_USER: "[Photoprism DB-User]"
      PHOTOPRISM_DATABASE_PASSWORD: "[Photoprism Database Password]"
      PHOTOPRISM_ADMIN_PASSWORD: "[Photoprism Admin Password]"       
      PHOTOPRISM_PUBLIC: "false"
      PHOTOPRISM_READONLY: "true"
    volumes:
      - photoprism_originals:/photoprism/originals
      - photoprism_storage:/photoprism/storage

  mariadb:
    image: mariadb:10.11
    restart: unless-stopped
    stop_grace_period: 5s
    security_opt:
      - seccomp:unconfined
      - apparmor:unconfined
    command: "[MariaDB Configuration Commands]"
    volumes:
      - mariadb_data:/var/lib/mysql
    environment:
      MARIADB_DATABASE: "photoprism"
      MARIADB_USER: "photoprism"
      MARIADB_PASSWORD: "[MariaDB User Password]"
      MARIADB_ROOT_PASSWORD: "[MariaDB Root Password]"

volumes:
  mariadb_data:
  photoprism_originals:
  photoprism_storage:

In the NGINX Proxy Manager, under "Advanced," I have added the following configuration:

nginx


location / {
    proxy_set_header Host $host;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header X-Forwarded-Proto $scheme;
    proxy_pass http://[IP-of-PhotoPrism-Container]:2342;
    proxy_read_timeout 90;
}

Despite these settings, I continue to receive errors suggesting that the requests are not being properly forwarded by the NGINX server to PhotoPrism.

My questions are:

  1. Are there specific settings I need to configure in the NGINX Proxy Manager for WebDAV?
  2. Could the issue lie in the PhotoPrism configuration, and if so, how should I adjust it?
  3. Has anyone had similar experiences or can provide insights?

Any help or guidance would be greatly appreciated. Thank you in advance!

Best regards, Peter

see my text above, there is everything you need

0

There are 0 best solutions below