Phase 1 & 2: full-stack family dashboard scaffold
- pnpm monorepo (apps/client + apps/server)
- Server: Express + node:sqlite with numbered migration runner,
REST API for all 9 features (members, events, chores, shopping,
meals, messages, countdowns, photos, settings)
- Client: React 18 + Vite + TypeScript + Tailwind + Framer Motion + Zustand
- Theme system: dark/light + 5 accent colors, CSS custom properties,
anti-FOUC script, ThemeToggle on every surface
- AppShell: collapsible sidebar, animated route transitions, mobile drawer
- Phase 2 features: Calendar (custom month grid, event chips, add/edit modal),
Chores (card grid, complete/reset, member filter, streaks),
Shopping (multi-list tabs, animated check-off, quick-add bar, member assign)
- Family member CRUD with avatar, color picker
- Settings page: theme/accent, photo folder, slideshow, weather, date/time
- Docker: multi-stage Dockerfile, docker-compose.yml, entrypoint with PUID/PGID
- Unraid: CA XML template, CLI install script, UNRAID.md guide
- .gitignore covering node_modules, dist, db files, secrets, build artifacts
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 21:56:30 -05:00
|
|
|
#!/bin/sh
|
|
|
|
|
set -e
|
|
|
|
|
|
|
|
|
|
# Resolve PUID/PGID (Unraid default: nobody=99, users=100)
|
|
|
|
|
PUID=${PUID:-99}
|
|
|
|
|
PGID=${PGID:-100}
|
|
|
|
|
|
|
|
|
|
echo "[entrypoint] Starting Family Planner (PUID=${PUID}, PGID=${PGID})"
|
|
|
|
|
|
2026-03-29 22:10:07 -05:00
|
|
|
# Resolve group: reuse existing group at PGID, or create a new one
|
|
|
|
|
if getent group "${PGID}" > /dev/null 2>&1; then
|
|
|
|
|
APP_GROUP=$(getent group "${PGID}" | cut -d: -f1)
|
|
|
|
|
echo "[entrypoint] Reusing existing group '${APP_GROUP}' (GID=${PGID})"
|
|
|
|
|
else
|
|
|
|
|
APP_GROUP=appgroup
|
|
|
|
|
addgroup -g "${PGID}" "${APP_GROUP}"
|
|
|
|
|
echo "[entrypoint] Created group '${APP_GROUP}' (GID=${PGID})"
|
Phase 1 & 2: full-stack family dashboard scaffold
- pnpm monorepo (apps/client + apps/server)
- Server: Express + node:sqlite with numbered migration runner,
REST API for all 9 features (members, events, chores, shopping,
meals, messages, countdowns, photos, settings)
- Client: React 18 + Vite + TypeScript + Tailwind + Framer Motion + Zustand
- Theme system: dark/light + 5 accent colors, CSS custom properties,
anti-FOUC script, ThemeToggle on every surface
- AppShell: collapsible sidebar, animated route transitions, mobile drawer
- Phase 2 features: Calendar (custom month grid, event chips, add/edit modal),
Chores (card grid, complete/reset, member filter, streaks),
Shopping (multi-list tabs, animated check-off, quick-add bar, member assign)
- Family member CRUD with avatar, color picker
- Settings page: theme/accent, photo folder, slideshow, weather, date/time
- Docker: multi-stage Dockerfile, docker-compose.yml, entrypoint with PUID/PGID
- Unraid: CA XML template, CLI install script, UNRAID.md guide
- .gitignore covering node_modules, dist, db files, secrets, build artifacts
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 21:56:30 -05:00
|
|
|
fi
|
2026-03-29 22:10:07 -05:00
|
|
|
|
|
|
|
|
# Resolve user: reuse existing user at PUID, or create a new one
|
|
|
|
|
if getent passwd "${PUID}" > /dev/null 2>&1; then
|
|
|
|
|
APP_USER=$(getent passwd "${PUID}" | cut -d: -f1)
|
|
|
|
|
echo "[entrypoint] Reusing existing user '${APP_USER}' (UID=${PUID})"
|
|
|
|
|
else
|
|
|
|
|
APP_USER=appuser
|
|
|
|
|
adduser -D -u "${PUID}" -G "${APP_GROUP}" "${APP_USER}"
|
|
|
|
|
echo "[entrypoint] Created user '${APP_USER}' (UID=${PUID})"
|
Phase 1 & 2: full-stack family dashboard scaffold
- pnpm monorepo (apps/client + apps/server)
- Server: Express + node:sqlite with numbered migration runner,
REST API for all 9 features (members, events, chores, shopping,
meals, messages, countdowns, photos, settings)
- Client: React 18 + Vite + TypeScript + Tailwind + Framer Motion + Zustand
- Theme system: dark/light + 5 accent colors, CSS custom properties,
anti-FOUC script, ThemeToggle on every surface
- AppShell: collapsible sidebar, animated route transitions, mobile drawer
- Phase 2 features: Calendar (custom month grid, event chips, add/edit modal),
Chores (card grid, complete/reset, member filter, streaks),
Shopping (multi-list tabs, animated check-off, quick-add bar, member assign)
- Family member CRUD with avatar, color picker
- Settings page: theme/accent, photo folder, slideshow, weather, date/time
- Docker: multi-stage Dockerfile, docker-compose.yml, entrypoint with PUID/PGID
- Unraid: CA XML template, CLI install script, UNRAID.md guide
- .gitignore covering node_modules, dist, db files, secrets, build artifacts
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 21:56:30 -05:00
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
# Ensure /data is owned by the app user so SQLite can write
|
|
|
|
|
mkdir -p /data
|
|
|
|
|
chown -R "${PUID}:${PGID}" /data
|
|
|
|
|
|
|
|
|
|
# Drop privileges and exec the CMD
|
|
|
|
|
exec su-exec "${PUID}:${PGID}" "$@"
|