Commit Graph

12 Commits

Author SHA1 Message Date
jason cfeee5dc2a fix: copy prisma.config.ts into runner so db push can find datasource URL
Without prisma.config.ts in the runner stage, prisma db push has no
datasource URL (schema.prisma no longer carries url in Prisma 7) and
silently skips creating the database. Also add set -e to the entrypoint
so any db push failure is visible in logs and stops the container.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-13 00:44:41 -05:00
jason b1fa70eba4 fix: create /app/data after COPY steps to prevent permission clobber
The mkdir was running before the standalone COPY, which could overwrite
/app/data contents or permissions. Move it to after all COPY statements
and use chmod 700 so only nextjs owns and can write the SQLite data dir.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-13 00:38:50 -05:00
jason 716b37c6f2 fix: use npm install in Docker so Alpine musl native bindings resolve
npm ci with a Windows-generated lockfile skips @libsql/linux-x64-musl
(optional native dep). Switching to npm install lets npm resolve the
correct platform-specific binary for the Alpine container. Also copy
node_modules into the runner stage so prisma db push and the libsql
native module are available at runtime.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-13 00:32:24 -05:00
jason ea5b4a955d fix: remove apk upgrade from Dockerfile base stage
apk upgrade hangs on slow/unreliable Alpine mirrors and is not needed
for a build. node:20-alpine is sufficiently up to date.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-13 00:24:52 -05:00
jason fcc04915c2 fix: migrate to Prisma 7 driver adapter (libsql) for SQLite
Prisma 7 removed support for `url` in schema.prisma datasources and the
`engineType = "library"` native binary engine. All connections now go
through a driver adapter.

- Remove engineType and url from schema.prisma (no longer supported)
- Configure prisma.config.ts with migrate.adapter using @libsql/client
- Instantiate PrismaClient with PrismaLibSQL adapter in src/lib/prisma.ts
- Add @libsql/client and @prisma/adapter-libsql dependencies
- Remove PRISMA_CLIENT_ENGINE_TYPE from Dockerfile (obsolete)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-12 23:49:58 -05:00
jason 3b743d81d4 docker 2026-03-12 23:34:19 -05:00
jason 13f53badc3 again? 2026-03-12 20:27:11 -05:00
jason e007d54fb3 claude ftw 2026-03-12 20:13:55 -05:00
jason f5e3a1e870 no turbo again 2026-03-12 20:02:25 -05:00
jason 5de0f52af7 prisma fixes 2026-03-12 19:15:56 -05:00
jason ce5eb2343d docker update 2026-03-12 19:00:31 -05:00
jason 4982e5392e initial commit 2026-03-12 17:09:22 -05:00