Full Stack Web Application
Frontend: React + Vite
Backend: FastAPI (Python)
Database: MySQL
OFS is a new organic retailer in Downtown San Jose. OFS’s mission is to improve accessibility of quality foods by providing a reliable online ordering and home delivery service for organic groceries. OFS plans to use a fleet of self-driving robotic delivery vehicles to reduce the hassle of shopping in a dense, traffic-congested downtown area.
This project is a full-stack web application that allows users to register, login, and interact with the OFS system.
The system consists of:
- React frontend (served by Vite on port 5173)
- FastAPI backend (served on port 8000)
- MySQL Database (default port 3306)
Install the following before setup:
python --versionnode -v
npm -v- Install MySQL Workbench
Open a terminal in the project root (where main.py is located).
python -m venv venv
venv\Scripts\activatepython3 -m venv venv
source venv/bin/activatepip install -r requirements.txt
Create a file named .env in the root directory:
DB_USER=root
DB_PASSWORD=YOUR_MYSQL_PASSWORD
DB_HOST=localhost
DB_PORT=3306
DB_NAME=ofs_dbReplace YOUR_MYSQL_PASSWORD with your actual MySQL password
univorn main:app --reload --port 8000Open a second terminal
cd frontend
npm installnpm run dev Frontend runs at:
http://localhost:5173
Open Command Prompt as Administrator:
net start MySQL80or start from:
services.msc -> MySQL80 -> Start
Using MySQL Workbench:
- Open Workbench
- Connect to your local instance
- Open
database/schema.sql - Click ⚡ Execute
You must run:
Then open:
http://localhost:5173