- Have Docker and docker compose installed
- Have node >= v18.0.0
We have deployed all our services using Google Cloud Platform. Thus, you will not need to run any of the services aside.
The code for all the services can be found in this respository and their respective links can be found in the report in this repository.
The project is hosted here.
To access the project, we have provided you with the following accounts that would grant you access to the application:
Admin Account:
username: [email protected]
password: password123
User Account:
username: [email protected]
password: password123
Alternatively, if you wish to create an account you can also choose to do so. If you require an Administrator account please contact the developers.
- Clone this repository.
- Ensure you have the following files:
1. frontend/.env
If you do not have any of these files, or any other files required for the Assignments, please contact the developers for a copy.
- Ensure that you do not have anything running on port 80, and run the following command from the root directory:
docker compose up --build
- The applcation can then be accessed at http://localhost.
Detailed below are the instructions required to run all Assignments from 1 to 5.
- Download the code from here and unzip it.
- Run the following commands
cd frontend
npm i
npm run dev
- The application is running here: http://localhost:5173
- Access the application using the following credentials:
username: [email protected]
password: password
- Download the code from here and unzip it.
- Ensure you don't have anything running on port 5173, 8000 and 8080.
- Ensure you have the following files:
1. frontend/.env
2. user-service/.env
3. question-service/.env
4. question-service/serviceAccount.json
- Ensure you have a postgres database running in the background locally and set it up with the following script
DROP TABLE IF EXISTS users;
CREATE TABLE users (
id SERIAL,
email VARCHAR(254) UNIQUE,
password VARCHAR(128),
salt VARCHAR(32),
PRIMARY KEY (email, password)
);
INSERT INTO users ("email", "password", "salt") VALUES ('[email protected]', '8979679e286b9130417aae3aeb750f78f07019c5ed3d409d13a228f990e5970cb8b3151d18e561cc3f00d1be20b0e369db6e86fdadc8bd68414010d6b245aa5e', 'caa238d2878974b52f64ec4cbec3953c');
- Fill up user-service/.env with the following details:
DB_USER=<DB USERNAME>
DB_HOST=localhost
DB_NAME=<NAME OF YOUR DATABASE>
DB_PASSWORD=<DB PASSWORD>
DB_PORT=<PORT OF YOUR DATABASE>
- To run the frontend:
cd frontend
npm i
npm run dev
- To run the Question Service
cd question-service
npm i
npm run start
- To run the User Service
cd user-service
npm i
npm run start
- The application is running here: http://localhost:5173
- To access the application, create an account using the Register button and login using the account created
- Alternatively, you can access the application with the account credentials:
username: [email protected]
password: password1
- Download the code from here and unzip it.
- Ensure you don't have anything running on port 5173, 8000 and 8080.
- Ensure you have the following files:
1. frontend/.env
2. user-service/.env
3. user-service/serviceAccount.json
4. question-service/.env
5. question-service/serviceAccount.json
- Ensure you have a postgres database running in the background locally and set it up with the following script
DROP TABLE IF EXISTS users;
CREATE TABLE users (
id SERIAL,
email VARCHAR(254) UNIQUE,
firebaseId VARCHAR(254) UNIQUE,
PRIMARY KEY (email, firebaseId),
);
- Fill up user-service/.env with the following details:
DB_USER=<DB USERNAME>
DB_HOST=localhost
DB_NAME=<NAME OF YOUR DATABASE>
DB_PASSWORD=<DB PASSWORD>
DB_PORT=<PORT OF YOUR DATABASE>
- To run the frontend:
cd frontend
npm i
npm run dev
- To run the Question Service
cd question-service
npm i
npm run start
- To run the User Service
cd user-service
npm i
npm run start
- The application is running here: http://localhost:5173
- To access the application, create an account using the Register button and login using the account created
- Alternatively, you can access the application with the account credentials:
Admin Account:
username: [email protected]
password: password123
User Account:
username: [email protected]
password: password123
- Download the code from here and unzip it.
- Ensure you don't have anything running on port 80, 8000 and 8080.
- Ensure you have Docker Engine running in the background
- Ensure you have the Docker plugin docker compose installed
- Ensure you have the following files:
1. .env
2. frontend/.env
3. user-service/.env
4. user-service/serviceAccount.json
5. question-service/.env
6. question-service/serviceAccount.json
- To run the application, run the following command:
docker compose up --build -d
- The application is running here: http://localhost:80
- To access the application, create an account using the Register button and login using the account created
- Alternatively, you can access the application with the account credentials:
Admin Account:
username: [email protected]
password: password123
User Account:
username: [email protected]
password: password123
- Remember to remove the containers after you are done using the following commands:
docker compose down -v
- Clone the repository
- Run the following commands
cd matching-service
npm install
- Place the service_account_key.json file in the matching sevice folder
- In the terminal run
export GOOGLE_APPLICATION_CREDENTIALS="service_account_key.json" - In the terminal run
npm start