a .env
file is required in the root directory with the following variables:
DATABASE_URL=<supabase postgres url>
SUPABASE_DB_PASSWORD=<supabase db password>
additionally, a .env.local
file is required in the root directory with the following variables:
PUBLIC_SUPABASE_URL=<supabase url>
PUBLIC_SUPABASE_ANON_KEY=<supabase anon key>
PUBLIC_CHATTER_WS_URL=<websocket server url>
Before running the project, make sure you supabase login
and run:
npm run migrate
to create the required tables, triggers, policies, and functions in the database.
git clone https://https://github.com/nathanielfernandes/cps630-project
cd cps630-project
npm install
npm run dev
npm run chatter
docker build -t tmu-marketplace-client -f Dockerfile .
docker run -p 3000:3000 tmu-marketplace-client
docker build -t tmu-marketplace-chatter -f ./services/Dockerfile ./services/chatter
docker run -p 3001:3001 tmu-marketplace-chatter
cd cps630-project
npm install
npm run build
node ./build/index.js
cd cps630-project/services/chatter
cargo build --release
./target/release/chatter
The following is a user manual on how to use the website.
To view and post listings, you must have an account. Click on the blue button on the top right corner "Sign in / Register". Create your account or log in with your existing account.
Click on either the "Wanted Listings", "Buy & Sell" or "Academic Services" tabs at the top of the page to browse the respective categories. You are now able to view the postings with their title, description, price, images, and seller email address.
While on a listings page, search through the listings using the search bar on the top right corner of the page. You can search keywords related to the title, description, price, or email.
You can save your particular query by bookmarking the tab.
While on a listings page, click on a listing to view its full details, including all attached images, location data, and user contact information.
Message users on a platform using the "messaging" tab on the bottom right of the website. Here you can view all your existing conversations, and enter any one of them.
To begin a conversation with a seller, click on a listing, and then click "Contact". A new chat will begin related to the specific listing.
To create a listing, click the yellow "Place an Ad" Button on the top left corner of the page.
From here, choose which type of listing you wish to create.
Create your listing by filling in the fields on the left side of the page. View your listing live update on the right side of the page.
Attach multiple images from your computer, or by dragging and dropping from an online source.
Fill in all the fields, and click "Submit". Your listing is now viewable by all users on the platform.
If you are an admin on the platform, you will have access to the admin dashboard. You can find it by clicking your user icon image and pressing "Admin Dashboard".
View site metrics such as listings count, and user count. View a table of listings related to these metrics.