Commit graph

5 commits

Author SHA1 Message Date
Vadym Samoilenko
d34071f9f8 fix: switch from nginx to Traefik for routing and SSL
Server uses Traefik (traefik-public network) with Cloudflare DNS
cert resolver. Nginx not needed. Add Traefik labels to app service,
connect to traefik-public + internal networks, remove nginx/certbot.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-23 14:39:32 +00:00
Vadym Samoilenko
4e23350bfc fix: run migrations via Next.js instrumentation.ts at startup
tsx v4 + Node.js 22 ESM does not handle extensionless .ts imports.
instrumentation.ts uses compiled/bundled code — no resolution issues.
Migrations run automatically before first request on every app start.
Removes external migrator container approach entirely.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-23 14:14:18 +00:00
Vadym Samoilenko
1348188a6c fix: dedicated migrator stage for payload migrate
Build stage runs pnpm build which changes ESM resolution context.
New migrator stage has deps+src only — clean env for tsx/payload migrate.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-23 14:04:34 +00:00
Vadym Samoilenko
ecc2c94e5f fix: run migrations from build stage (has pnpm)
Runner stage is minimal — no pnpm. Add migrator service using
build target which has full node_modules + pnpm.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-23 13:59:57 +00:00
Vadym Samoilenko
fc4688cc6f feat: add production deploy script and docker-compose
- deploy.sh: idempotent deploy for Ubuntu server (Docker + Nginx + SSL)
- docker-compose.prod.yml: production compose (runner target, localhost-only port)
- .gitignore: exclude .env.production and .deploy-config

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-23 13:41:29 +00:00