From e50dafe3e1db7b1ce626994c4920e1023d5d2f10 Mon Sep 17 00:00:00 2001 From: Michael Mayer Date: Wed, 10 Dec 2025 11:26:40 +0100 Subject: [PATCH] Setup: Add OLLAMA_API_KEY and OLLAMA_BASE_URL to Compose files #5361 Signed-off-by: Michael Mayer --- compose.nvidia.yaml | 2 +- compose.postgres.yaml | 6 ++++++ compose.yaml | 4 +++- setup/docker/arm64/compose.yaml | 4 +++- setup/docker/compose.yaml | 4 +++- setup/docker/macos/compose.yaml | 6 ++++++ setup/docker/nvidia/compose.yaml | 4 +++- setup/docker/scheduler/compose.yaml | 6 ++++++ setup/docker/sqlite/compose.yaml | 6 ++++++ setup/docker/windows/compose.yaml | 6 ++++++ 10 files changed, 43 insertions(+), 5 deletions(-) diff --git a/compose.nvidia.yaml b/compose.nvidia.yaml index 097eb91fa..7f9ed46b2 100644 --- a/compose.nvidia.yaml +++ b/compose.nvidia.yaml @@ -121,7 +121,7 @@ services: PHOTOPRISM_THUMB_UNCACHED: "true" # enables on-demand thumbnail rendering (high memory and cpu usage) ## Run/install on first startup (options: update tensorflow https intel gpu davfs yt-dlp): PHOTOPRISM_INIT: "https tensorflow-gpu" - ## Computer Vision API (https://docs.photoprism.app/getting-started/config-options/#computer-vision): + ## Computer Vision (https://docs.photoprism.app/getting-started/config-options/#computer-vision): PHOTOPRISM_VISION_API: "true" # server: enables service API endpoints under /api/v1/vision (requires access token) PHOTOPRISM_VISION_URI: "" # client: service URI, e.g. http://hostname/api/v1/vision (leave blank to disable) PHOTOPRISM_VISION_KEY: "" # client: service access token (for authentication) diff --git a/compose.postgres.yaml b/compose.postgres.yaml index a6f91e103..fcbcf5588 100644 --- a/compose.postgres.yaml +++ b/compose.postgres.yaml @@ -68,6 +68,12 @@ services: PHOTOPRISM_JPEG_SIZE: 7680 # size limit for converted image files in pixels (720-30000) ## Run/install on first startup (options: update tensorflow https intel gpu davfs yt-dlp): PHOTOPRISM_INIT: "https" + ## Computer Vision (https://docs.photoprism.app/getting-started/config-options/#computer-vision): + PHOTOPRISM_VISION_API: "true" # server: enables service API endpoints under /api/v1/vision (requires access token) + PHOTOPRISM_VISION_URI: "" # client: service URI, e.g. http://hostname/api/v1/vision (leave blank to disable) + PHOTOPRISM_VISION_KEY: "" # client: service access token (for authentication) + OLLAMA_BASE_URL: "http://ollama:11434" # use "https://ollama.com" for Ollama Cloud + OLLAMA_API_KEY: "" # API key required to access Ollama (optional) ## External dependencies and tools: TF_CPP_MIN_LOG_LEVEL: 1 GOCACHE: "/go/src/github.com/photoprism/photoprism/.local/gocache" diff --git a/compose.yaml b/compose.yaml index 6ef9aeadc..53e34126d 100644 --- a/compose.yaml +++ b/compose.yaml @@ -131,10 +131,12 @@ services: # PHOTOPRISM_FFMPEG_BITRATE: "64" # video bitrate limit in Mbps (default: 60) ## Run/install on first startup (options: update tensorflow https intel gpu davfs yt-dlp): PHOTOPRISM_INIT: "https" - ## Computer Vision API (https://docs.photoprism.app/getting-started/config-options/#computer-vision): + ## Computer Vision (https://docs.photoprism.app/getting-started/config-options/#computer-vision): PHOTOPRISM_VISION_API: "true" # server: enables service API endpoints under /api/v1/vision (requires access token) PHOTOPRISM_VISION_URI: "" # client: service URI, e.g. http://hostname/api/v1/vision (leave blank to disable) PHOTOPRISM_VISION_KEY: "" # client: service access token (for authentication) + OLLAMA_BASE_URL: "http://ollama:11434" # use "https://ollama.com" for Ollama Cloud + OLLAMA_API_KEY: "" # API key required to access Ollama (optional) ## External dependencies and tools: TF_CPP_MIN_LOG_LEVEL: 1 GOCACHE: "/go/src/github.com/photoprism/photoprism/.local/gocache" diff --git a/setup/docker/arm64/compose.yaml b/setup/docker/arm64/compose.yaml index ca69a1ed5..05ff30c7c 100644 --- a/setup/docker/arm64/compose.yaml +++ b/setup/docker/arm64/compose.yaml @@ -101,10 +101,12 @@ services: PHOTOPRISM_DATABASE_PASSWORD: "insecure" # MariaDB database password, must be the same as MARIADB_PASSWORD ## Run/install on first startup (https://docs.photoprism.app/getting-started/config-options/#docker-image): PHOTOPRISM_INIT: "https yt-dlp" # options: update https tensorflow tensorflow-gpu intel gpu davfs yt-dlp - ## Computer Vision API (https://docs.photoprism.app/getting-started/config-options/#computer-vision): + ## Computer Vision (https://docs.photoprism.app/getting-started/config-options/#computer-vision): PHOTOPRISM_VISION_API: "false" # server: enables service API endpoints under /api/v1/vision (requires access token) PHOTOPRISM_VISION_URI: "" # client: service URI, e.g. http://hostname/api/v1/vision (leave blank to disable) PHOTOPRISM_VISION_KEY: "" # client: service access token (for authentication) + OLLAMA_BASE_URL: "http://ollama:11434" # use "https://ollama.com" for Ollama Cloud + OLLAMA_API_KEY: "" # API key required to access Ollama (optional) ## Video Transcoding (https://docs.photoprism.app/getting-started/advanced/transcoding/): # PHOTOPRISM_FFMPEG_ENCODER: "software" # H.264/AVC encoder (software, intel, nvidia, apple, raspberry, or vaapi) # PHOTOPRISM_FFMPEG_SIZE: "1920" # video size limit in pixels (720-7680) (default: 3840) diff --git a/setup/docker/compose.yaml b/setup/docker/compose.yaml index 7d30c3693..89c440e89 100644 --- a/setup/docker/compose.yaml +++ b/setup/docker/compose.yaml @@ -91,10 +91,12 @@ services: PHOTOPRISM_DATABASE_PASSWORD: "insecure" # MariaDB database password, must be the same as MARIADB_PASSWORD ## Run/install on first startup (https://docs.photoprism.app/getting-started/config-options/#docker-image): PHOTOPRISM_INIT: "https tensorflow" # options: update https tensorflow tensorflow-gpu intel gpu davfs yt-dlp - ## Computer Vision API (https://docs.photoprism.app/getting-started/config-options/#computer-vision): + ## Computer Vision (https://docs.photoprism.app/getting-started/config-options/#computer-vision): PHOTOPRISM_VISION_API: "false" # server: enables service API endpoints under /api/v1/vision (requires access token) PHOTOPRISM_VISION_URI: "" # client: service URI, e.g. http://hostname/api/v1/vision (leave blank to disable) PHOTOPRISM_VISION_KEY: "" # client: service access token (for authentication) + OLLAMA_BASE_URL: "http://ollama:11434" # use "https://ollama.com" for Ollama Cloud + OLLAMA_API_KEY: "" # API key required to access Ollama (optional) ## Video Transcoding (https://docs.photoprism.app/getting-started/advanced/transcoding/): # PHOTOPRISM_FFMPEG_ENCODER: "software" # H.264/AVC encoder (software, intel, nvidia, apple, raspberry, or vaapi) # PHOTOPRISM_FFMPEG_SIZE: "1920" # video size limit in pixels (720-7680) (default: 3840) diff --git a/setup/docker/macos/compose.yaml b/setup/docker/macos/compose.yaml index 1a897793e..ff4c21e8a 100644 --- a/setup/docker/macos/compose.yaml +++ b/setup/docker/macos/compose.yaml @@ -84,6 +84,12 @@ services: PHOTOPRISM_SITE_AUTHOR: "" # meta site author ## Run/install on first startup, see https://github.com/photoprism/photoprism/blob/develop/scripts/dist/Makefile: PHOTOPRISM_INIT: "https tensorflow" # common options: update https tensorflow tensorflow-gpu intel gpu davfs yt-dlp + ## Computer Vision (https://docs.photoprism.app/getting-started/config-options/#computer-vision): + PHOTOPRISM_VISION_API: "false" # server: enables service API endpoints under /api/v1/vision (requires access token) + PHOTOPRISM_VISION_URI: "" # client: service URI, e.g. http://hostname/api/v1/vision (leave blank to disable) + PHOTOPRISM_VISION_KEY: "" # client: service access token (for authentication) + OLLAMA_BASE_URL: "http://ollama:11434" # use "https://ollama.com" for Ollama Cloud + OLLAMA_API_KEY: "" # API key required to access Ollama (optional) ## Video Transcoding (https://docs.photoprism.app/getting-started/advanced/transcoding/): # PHOTOPRISM_FFMPEG_ENCODER: "software" # H.264/AVC encoder (software, intel, nvidia, apple, raspberry, or vaapi) # PHOTOPRISM_FFMPEG_SIZE: "1920" # video size limit in pixels (720-7680) (default: 3840) diff --git a/setup/docker/nvidia/compose.yaml b/setup/docker/nvidia/compose.yaml index 938c8422d..c04b8d736 100644 --- a/setup/docker/nvidia/compose.yaml +++ b/setup/docker/nvidia/compose.yaml @@ -95,10 +95,12 @@ services: PHOTOPRISM_DATABASE_PASSWORD: "insecure" # MariaDB database password, must be the same as MARIADB_PASSWORD ## Run/install on first startup, see https://github.com/photoprism/photoprism/blob/develop/scripts/dist/Makefile: PHOTOPRISM_INIT: "https tensorflow-gpu yt-dlp" # common options: update https tensorflow tensorflow-gpu intel gpu davfs yt-dlp - ## Computer Vision API (https://docs.photoprism.app/getting-started/config-options/#computer-vision): + ## Computer Vision (https://docs.photoprism.app/getting-started/config-options/#computer-vision): PHOTOPRISM_VISION_API: "false" # server: enables service API endpoints under /api/v1/vision (requires access token) PHOTOPRISM_VISION_URI: "" # client: service URI, e.g. http://hostname/api/v1/vision (leave blank to disable) PHOTOPRISM_VISION_KEY: "" # client: service access token (for authentication) + OLLAMA_BASE_URL: "http://ollama:11434" # use "https://ollama.com" for Ollama Cloud + OLLAMA_API_KEY: "" # API key required to access Ollama (optional) ## Video Transcoding (https://docs.photoprism.app/getting-started/advanced/transcoding/): PHOTOPRISM_FFMPEG_ENCODER: "nvidia" # H.264/AVC encoder (software, intel, nvidia, apple, raspberry, or vaapi) PHOTOPRISM_FFMPEG_SIZE: "1920" # video size limit in pixels (720-7680) (default: 3840) diff --git a/setup/docker/scheduler/compose.yaml b/setup/docker/scheduler/compose.yaml index 61a1e227f..87fb4514d 100644 --- a/setup/docker/scheduler/compose.yaml +++ b/setup/docker/scheduler/compose.yaml @@ -88,6 +88,12 @@ services: PHOTOPRISM_SITE_AUTHOR: "" # meta site author ## Run/install on first startup, see https://github.com/photoprism/photoprism/blob/develop/scripts/dist/Makefile: PHOTOPRISM_INIT: "https tensorflow" # common options: update https tensorflow tensorflow-gpu intel gpu davfs yt-dlp + ## Computer Vision (https://docs.photoprism.app/getting-started/config-options/#computer-vision): + PHOTOPRISM_VISION_API: "false" # server: enables service API endpoints under /api/v1/vision (requires access token) + PHOTOPRISM_VISION_URI: "" # client: service URI, e.g. http://hostname/api/v1/vision (leave blank to disable) + PHOTOPRISM_VISION_KEY: "" # client: service access token (for authentication) + OLLAMA_BASE_URL: "http://ollama:11434" # use "https://ollama.com" for Ollama Cloud + OLLAMA_API_KEY: "" # API key required to access Ollama (optional) ## Video Transcoding (https://docs.photoprism.app/getting-started/advanced/transcoding/): # PHOTOPRISM_FFMPEG_ENCODER: "software" # H.264/AVC encoder (software, intel, nvidia, apple, raspberry, or vaapi) # PHOTOPRISM_FFMPEG_SIZE: "1920" # video size limit in pixels (720-7680) (default: 3840) diff --git a/setup/docker/sqlite/compose.yaml b/setup/docker/sqlite/compose.yaml index 9bead24f3..0ad7ad61e 100644 --- a/setup/docker/sqlite/compose.yaml +++ b/setup/docker/sqlite/compose.yaml @@ -81,6 +81,12 @@ services: PHOTOPRISM_SITE_AUTHOR: "" # meta site author ## Run/install on first startup, see https://github.com/photoprism/photoprism/blob/develop/scripts/dist/Makefile: PHOTOPRISM_INIT: "https tensorflow" # common options: update https tensorflow tensorflow-gpu intel gpu davfs yt-dlp + ## Computer Vision (https://docs.photoprism.app/getting-started/config-options/#computer-vision): + PHOTOPRISM_VISION_API: "false" # server: enables service API endpoints under /api/v1/vision (requires access token) + PHOTOPRISM_VISION_URI: "" # client: service URI, e.g. http://hostname/api/v1/vision (leave blank to disable) + PHOTOPRISM_VISION_KEY: "" # client: service access token (for authentication) + OLLAMA_BASE_URL: "http://ollama:11434" # use "https://ollama.com" for Ollama Cloud + OLLAMA_API_KEY: "" # API key required to access Ollama (optional) ## Video Transcoding (https://docs.photoprism.app/getting-started/advanced/transcoding/): # PHOTOPRISM_FFMPEG_ENCODER: "software" # H.264/AVC encoder (software, intel, nvidia, apple, raspberry, or vaapi) # PHOTOPRISM_FFMPEG_SIZE: "1920" # video size limit in pixels (720-7680) (default: 3840) diff --git a/setup/docker/windows/compose.yaml b/setup/docker/windows/compose.yaml index ed41af12e..bbdea82c9 100644 --- a/setup/docker/windows/compose.yaml +++ b/setup/docker/windows/compose.yaml @@ -89,6 +89,12 @@ services: PHOTOPRISM_SITE_CAPTION: "AI-Powered Photos App" PHOTOPRISM_SITE_DESCRIPTION: "" # meta site description PHOTOPRISM_SITE_AUTHOR: "" # meta site author + ## Computer Vision (https://docs.photoprism.app/getting-started/config-options/#computer-vision): + PHOTOPRISM_VISION_API: "false" # server: enables service API endpoints under /api/v1/vision (requires access token) + PHOTOPRISM_VISION_URI: "" # client: service URI, e.g. http://hostname/api/v1/vision (leave blank to disable) + PHOTOPRISM_VISION_KEY: "" # client: service access token (for authentication) + OLLAMA_BASE_URL: "http://ollama:11434" # use "https://ollama.com" for Ollama Cloud + OLLAMA_API_KEY: "" # API key required to access Ollama (optional) ## Video Transcoding (https://docs.photoprism.app/getting-started/advanced/transcoding/): # PHOTOPRISM_FFMPEG_ENCODER: "software" # H.264/AVC encoder (software, intel, nvidia, apple, raspberry, or vaapi) # PHOTOPRISM_FFMPEG_SIZE: "1920" # video size limit in pixels (720-7680) (default: 3840)