fix: serve uploaded images via API route (public/ is read-only in production)
All checks were successful
Deploy to Production / Build and Deploy (push) Successful in 42s

Next.js bakes public/ at build time — dynamically uploaded files were
never served in Docker standalone mode. Store uploads in data/uploads/
and serve via /api/uploads/ with a rewrite for backward compatibility.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
2026-04-27 22:56:22 +02:00
parent ae89f8a014
commit 0fbb8aa599
8 changed files with 81 additions and 16 deletions

View File

@@ -50,7 +50,7 @@ services:
# - OLLAMA_MODEL=granite4:latest
volumes:
# Persist uploaded images and files
- keep-uploads:/app/public/uploads
- keep-uploads:/app/data/uploads
# Optional: Mount custom SSL certificates
# - ./certs:/app/certs:ro