84bbf5ac4b
Entrypoint now runs as root, fixes ownership of /app/data to nextjs:nodejs (uid 1001), then drops privileges via su before starting the app. This fixes 'unable to open database file' when the host data/ directory is created by Docker as root and is not writable by the nextjs user. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
6 lines
105 B
Bash
Executable File
6 lines
105 B
Bash
Executable File
#!/bin/sh
|
|
set -e
|
|
mkdir -p /app/data
|
|
chown -R 1001:1001 /app/data
|
|
exec su -c "exec node server.js" nextjs
|