Skip to content

Tonio2/boilerplate

Repository files navigation

Project Name

Description

This project is a full-stack application with a React frontend and an Express backend. It includes user authentication, email verification, password reset, and more.

For more detailed documentation, please refer to the prd.

Prerequisites

Installation

  1. Clone the repository:
git clone https://github.com/Tonio2/boilerplate.git
cd boilerplate
  1. Create environment variable files:
# Docker env variables
cp .env.example .env

# Server environment variables
cd ../server
cp .env.example .env

# Client environment variables
cd ../client
cp .env.example .env
  1. Update the .env files with your configuration.

  2. Install dependencies for both client and server:

# Install server dependencies
cd server
npm install

# Install client dependencies
cd ../client
npm install
  1. Initiate db schemas:
# Start db
docker compose up -d

# Initiate schemas
cd server
npm run db:push

Running the Project

  1. Start the postgres server:
docker compose up -d
  1. Start the backend server:
cd server
npm run dev
  1. Start the frontend client:
cd client
npm start

Push to prod

TODO

Your app is accessible at http://localhost:5000 and the api at http://localhost:5000/api

Database Management

Development Commands

# Push schema changes to database (development only)
npm run db:push

# Generate migration files
npm run db:generate

# Run migrations (production)
npm run db:migrate

# Open Drizzle Studio (database GUI)
npm run db:studio

Accessing the Database

Via Drizzle Studio:

cd server
npm run db:studio

Opens at https://local.drizzle.studio

Via psql CLI:

docker exec -it boilerplate-postgres psql -U postgres -d boilerplate

Via any PostgreSQL client:

  • Host: localhost
  • Port: 5432
  • Database: boilerplate
  • Username: postgres
  • Password: postgres

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published