Skip to content

Latest commit

 

History

History
53 lines (43 loc) · 1.04 KB

File metadata and controls

53 lines (43 loc) · 1.04 KB

How to Run This Thing 🚀

Hey! Here's how to get the project running on your machine. It's pretty straightforward.

What you need

Make sure you have these installed:

  • Node.js (for running the code)
  • PostgreSQL (the database)
  • Redis (for the locking stuff)

Step 1: Install Dependencies

Open a terminal in the project folder and run:

npm install

Then go to the client folder and do the same:

cd client
npm install
cd ..

Step 2: Set up the Database

You need to create a database called bookd.

# If you have psql installed
createdb bookd

Then, seed the database with some fake data so it's not empty:

npm run seed

This creates some test users like customer@example.com (password: password123).

Step 3: Run it!

You need two terminals open.

Terminal 1 (Backend):

npm start

This runs the server on port 3000.

Terminal 2 (Frontend):

cd client
npm run dev

This opens the website on port 5173.

That's it! Go to http://localhost:5173 and log in.