This document will guide you through the process of setting up your local development environment for ladderly.io.
- Install packages and dependencies.
npm i
- Create a database in Supabase and gather connection string-literal. You are going to need it in the next steps. The connection string is composed of named substrings which have values that might look like:
host: aws-0-us-west-1.pooler.supabase.com
db: postgres
port: 5432
user: postgres.zrpwqlogwfcxwcuyfnmd
password: [PASSWORD_WITHOUT_SQUARE_BRACKETS]
- Create copy .env to .env.local and provide the connection-string value to the key
DATABASE_URL
DATABASE_URL=postgres://postgres.zrpwqlogwfcxwcuyfnmd:[PASSWORD_WITHOUT_SQUARE_BRACKETS]@aws-0-us-west-1.pooler.supabase.com:5432/postgres
- Generate tables and columns in your Supabase Postgres database.
npx blitz prisma generate
npx blitz prisma migrate dev
- Run the app locally.
npm run dev
# alternatively: `npx blitz dev`
Q: I want to setup local development environment with local database. A: For local database to work, you are may need to configure a local postgres pooler. There is currently no supported path for this. Instead, it is recommended to use a cloud Postgres instance, and Ladderly particularly recommends Supabase.
Q: Where can I find more information on creating the database on supabase? A: Find more information about this here https://supabase.com/docs/guides/database/overview
Make sure the connection string literal has no typos in it.
Make sure the password is correct and you don't have any braces after the colon :
If you just created the db at Supabase, give it about 45 minutes to propagate.