From afeefbf19d5a6f48361646da51b2534c728fbae6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ullrich=20Sch=C3=A4fer?= Date: Wed, 25 Mar 2026 01:26:16 +0100 Subject: [PATCH] Fix production deploy: TypeScript support + DB schema push MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Planner crashed because Node.js couldn't handle .ts imports — add --experimental-strip-types to the CMD. Journal crashed because the database had no schemas — add drizzle-kit push to the deploy script. Co-Authored-By: Claude Opus 4.6 (1M context) --- .github/workflows/cd.yml | 7 ++++++- apps/planner/Dockerfile | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index 5c5f17a..2576d96 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -108,8 +108,13 @@ jobs: done fi - # Pull latest images and restart + # Pull latest images docker compose pull + + # Push database schema (starts postgres, waits for healthy) + docker compose run --rm journal npx drizzle-kit push --config /app/packages/db/drizzle.config.ts --force + + # Start all services docker compose up -d --remove-orphans # Verify services are running diff --git a/apps/planner/Dockerfile b/apps/planner/Dockerfile index 3167d82..ee02008 100644 --- a/apps/planner/Dockerfile +++ b/apps/planner/Dockerfile @@ -30,4 +30,4 @@ COPY --from=build /app/packages ./packages WORKDIR /app/apps/planner EXPOSE 3001 ENV PORT=3001 -CMD ["node", "server.ts"] +CMD ["node", "--experimental-strip-types", "server.ts"]