fix(deploy): stop on unwritable .titano folders and document proxies and host networking

- Entrypoint: an existing .titano folder or subfolder that PUID:PGID cannot
  write stops the container with a one-line error instead of a restart loop;
  it is never chowned.
- Compose and README: with network_mode host, publish PostgreSQL on loopback
  and set TITANO_DB_HOST to 127.0.0.1; behind a proxy, list it in
  TITANO_TRUSTED_PROXIES (loopback only by default). Unraid template gains a
  Trusted proxies variable.
- README: what the Windows server requires of its data folder and archive.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
This commit is contained in:
Claude committed 2026-10-12 11:08:12 +00:00
1 parent df2d4b4316
commit 23f43a505e
4 files changed
+25 -8

No files matched your search

+8
View File
@@ -35,6 +35,14 @@ if [ "$(id -u)" = "0" ]; then
exit 1
fi
fi
# The server writes into the archive's .titano folders at once (staging, trash, locks); one left to root by an
# earlier run as root, or copied in by root, would stop it in a restart loop. Reported, never chowned.
for dir in "$ARCHIVE/.titano" "$ARCHIVE/.titano"/*/; do
if [ -d "$dir" ] && ! as_user test -w "$dir"; then
echo "error: ${dir%/} is not writable by $PUID:$PGID; give that user write access to it on the host (for example chown -R $PUID:$PGID <archive>/.titano)" >&2
exit 1
fi
done
exec setpriv --reuid="$PUID" --regid="$PGID" --clear-groups -- dotnet /app/Titano.Server.dll "$@"
fi