- Install Docker Desktop if you haven't already. This should contain Docker, as well as the Docker Compose service that allows multiple Docker containers to be run easily.
- Open Docker Desktop.
- Setup the two environment variable files in
./user-service/.env
and./question-service/.env
using the.env.sample
template found within these folders. - Setup the environment variable file
./.env
with the port numbers you want to use for the respective frontend and backend services using the./.env.sample
template. Defaults are3000
forquestion-service
,4000
foruser-service
,5000
formatching-service
, and5173
for frontend. - Run the command
docker compose build --no-cache
to build the Dockerfiles for the user service and question service. This should create new Docker images for the user service (cs3219-ay2425s1-project-g36-user
) and the question service (cs3219-ay2425s1-project-g36-question
). - Run the command
docker compose up -d
to run the user and question services together. - You should be able to visit the user service on
http://localhost:4000
and the question service onhttp://localhost:3000
. You may test by viewing the question list onhttp://localhost:3000/questions
. - To stop running the user and question service in the Docker containers, you may run the command
docker compose down
. - To reflect code changes, you can
docker compose down
thendocker compose up -d
again to restart the backend services.
- You can choose to develop individual microservices within separate folders within this repository OR use individual repositories (all public) for each microservice.
- In the latter scenario, you should enable sub-modules on this GitHub classroom repository to manage the development/deployment AND add your mentor to the individual repositories as a collaborator.
- The teaching team should be given access to the repositories as we may require viewing the history of the repository in case of any disputes or disagreements.