Skip to content

fix: unblock fresh clone install and docker setup - #2

Merged
Denver-sn merged 1 commit into
Code-for-Senegal:mainfrom
khossdev:fix/fresh-clone-setup
Sep 6, 2026
Merged

Denver-sn merged 1 commit into
Code-for-Senegal:mainfrom
khossdev:fix/fresh-clone-setup

Conversation

@khossdev

@khossdev khossdev commented Sep 6, 2026 •

Copy link
Copy Markdown
Contributor

What

  • Use process.env['DATABASE_URL'] instead of env() in apps/api/prisma.config.ts so prisma generate (postinstall) works without a .env.
  • Set real allowBuilds booleans in pnpm-workspace.yaml and remove obsolete onlyBuiltDependencies.
  • Reorder README / CONTRIBUTING so .env files are created before pnpm install.
  • Include prisma.config.ts in the API typecheck config.

Fixes #1

Why

A fresh clone following the docs fails before the stack can start:

  1. env('DATABASE_URL') throws when unset, so pnpm install dies on Prisma postinstall.
  2. allowBuilds placeholders (set this to true or false) leave builds unreviewed under pnpm 11 strictDepBuilds, so install / pnpm docker:up exit with ERR_PNPM_IGNORED_BUILDS.

Testing

  • pnpm install succeeds after .env copy (Prisma client generated)
  • pnpm install no longer reports ERR_PNPM_IGNORED_BUILDS (lifecycle scripts run for prisma, argon2, esbuild, etc.)
  • pnpm docker:up starts the compose stack
  • With .env present → pnpm db:migrate still works
  • Fresh clone without .env → pnpm install still succeeds (Prisma generate only)

Screenshots

N/A — setup / config fix, no UI changes.

@Denver-sn
Denver-sn merged commit 3ee5f97 into Code-for-Senegal:main Sep 6, 2026
1 check passed
@Denver-sn

Copy link
Copy Markdown
Collaborator

Thanks @khossdev for the fix
Gg !

@khossdev
khossdev deleted the fix/fresh-clone-setup branch September 6, 2026 22:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Fresh clone setup fails: Prisma postinstall needs DATABASE_URL + pnpm allowBuilds placeholders

2 participants