From 793d03a3d46d747156007389cac6a74de56c8bee Mon Sep 17 00:00:00 2001 From: zelus_pudding Date: Mon, 11 Nov 2024 16:35:48 -0600 Subject: [PATCH] Add DB seeding detail --- README.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 8ff794b..41c5c13 100644 --- a/README.md +++ b/README.md @@ -31,12 +31,13 @@ A highly performant e-commerce template using Next.js and AI generated content b ### Local dev - Run `vc env pull` to get a `.env.local` file with your db credentials. -- Run `pnpm install` && `pnpm dev` to start developing +- Run `pnpm install` && `pnpm dev` to start developing. +- The data/data.zip includes a ~300 MB data.sql file with the full schema and 1,000,000+ products (*Note, the data exceeds the size limit allowed by the free tier for Neon on Vercel* [see more](https://vercel.com/docs/storage/vercel-postgres/usage-and-pricing#pricing)). To seed Vercel Postgres with this data: + - Unzip data.zip to data.sql. + - Run `psql "YOUR_CONNECTION_STRING" -f data.sql`. - For DB migrations with `drizzle-kit`: - Make sure `?sslmode=required` is added to the `POSTGRES_URL` env for dev - Run `pnpm db:push` to apply schema to your db -- The data/data.zip includes a ~300 MB data.sql file with the full schema and 1,000,000+ products - - *NOTE: The data exceeds the size limit allowed by the free tier for Neon on Vercel* [see more](https://vercel.com/docs/storage/vercel-postgres/usage-and-pricing#pricing) ### Performance