Blog software themed around pizza with customizability. Creating my own blog software has actually been something I've been meaning to do since pre-2019. This is my attempt at finally getting around to it!
- Node.js 20+
- PostgreSQL
Set up the environment. .env holds the database URL that Prisma reads, and
.env.local holds what the app reads at runtime:
# .env
DATABASE_URL="postgresql://user:password@localhost:5432/pizzablog"# .env.local
DATABASE_URL="postgresql://user:password@localhost:5432/pizzablog"
SESSION_SECRET="any-long-random-string"
DUMMY_PASSWORD="any-placeholder-password-for-hashes"Run the app locally:
npm install
npx prisma migrate dev
npm run devThen open http://localhost:3000, with the admin login at http://localhost:3000/admin/login.
Run the app in production mode:
npm install
npx prisma migrate deploy
npm run build
npm startThe schema lives in prisma/schema.prisma. After editing it, create a
migration and regenerate the client:
npx prisma migrate dev --name what_changed