Skip to content

sookiemonster/Fitch-Codeathon

Repository files navigation

EcoWare 🌎🍽️

Project By: Tiffany Fu, Daniel Sooknanan, Dante Betancourt, Solayjon Ollanazarov
Team Discovery
Wireframe
EcoWare API Endpoint Documentation
EcoWare Marketing Plan

Note : user_app branch has the fully functioning user app

How to Deploy

Clone the repo

git clone https://github.com/sookiemonster/Fitch-Codeathon ecoware

cd ecoware

Database

We used PostgreSQL for our database with Prisma ORM.

How to setup

  1. Install PostgreSQL For Linux

    sudo apt install postgresql
    

    For macOS (Homebrew)

    brew install postgresql
    
  2. Start PostgreSQL For Linux

    sudo service postgresql start
    

    For macOS (Homebrew)

    brew services start postgresql
    
  3. Create a User and Database Log into the PostgreSQL shel:

    sudo -u postgres psql
    

    Create a new user and database:

    CREATE USER myuser WITH PASSWORD 'mypassword';
    CREATE DATABASE mydb OWNER myuser;
    
  4. Integrate Prisma Create a new .env file inside the server folder with the connection URL:

    DATABASE_URL="postgresql://myuser:mypassword@localhost:5432/mydb"
    

Backend Server

  1. Go to the server folder

    cd server
    
  2. Install all the necessary packages

    npm install
    
  3. Generate the Prisma client and seed the database:

    npm run prisma
    
  4. Run the server

    npm run server
    

    (runs on port 5000)

(Optional)

  1. GUI for the database
    npm run studio
    
    (runs on port 5555)

Washer Dashboard

  1. Go to the web-client folder

    cd web-client
    
  2. Install all the necessary packages

    npm install
    
  3. Run the web client

    npm run start
    

    (runs on port 3000)

Vendor Web Dashboard

  1. Go to the next-web folder

    cd next-web
    
  2. Install all the necessary packages

    npm install
    
  3. Run the web client

    npm run dev
    

    (runs on port 3010)

User Mobile App

  1. Go to the frontend-mobile-user

    cd frontend-mobile-user
    
  2. Install all the necessary packages

    npm install
    
  3. Create a new .env file inside the frontend-mobile-user folder with the IP and PORT where the backend server is running: EXPO_PUBLIC_ADDRESS = "<ip_address>:<port>" ip_address cant be localhost port should be 5000 ( unless u changed the server port ) dont include 'http://' or '/' after the port

  4. Run the mobile client

    npx expo start
    

    (runs on port 8081)

  5. Follow the instructions on the terminal

Vendor Mobile App

  1. Go to the frontend-mobile-vendor

    cd frontend-mobile-Vendor
    
  2. Install all the necessary packages

    npm install
    
  3. Create a new .env file inside the frontend-mobile-user folder with the IP and PORT where the backend server is running: EXPO_PUBLIC_ADDRESS = "<ip_address>:<port>" ip_address cant be localhost port should be 5000 ( unless u changed the server port ) dont include 'http://' or '/' after the port

  4. Run the mobile client

    npx expo start
    

    (runs on port 8082)

  5. Follow the instructions on the terminal

Test Accounts

Vendors : login : v1@t.com password: test1

login : v2@t.com password: test2

login : v3@t.com password: test3

Users : login : u1@t.com password: test1

login : u2@t.com password: test2

login : u3@t.com password: test3

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •