This depo contains the code for a Web Technology project : Social Interests.
This project consists of a web application that allows users to create a profile and share their interests. In order to deploy the application, you have two options :
To deploy the application on Docker, you have to install Docker and Docker Compose on your computer. Then :
- Configure nginx to serve the application. A sample config file is provided in
./frontend/nginx/conf/frontend.conf
. - Modify the
config.js
in./frontend/src/
to match your needs. - Modify the environment variables in
docker-compose.yml
to match your needs. - Launch
docker-compose up
to start the application.
The frontend is then served via nginx
, using certbot to generate a letsencrypt
certificate. The api is also served via nginx
, using the same certificate, using a reverse proxy.
To deploy the application locally (for development, for example), you have to do the following
Install MongoDB on your computer, then run the following command to start the database.
systemctl enable mongodb
systemctl start mongodb
mongorestore dump/
- Modify the
config.js
in./backend/
to match your needs.
cd backend
npm install
npm start
The backend will run on the port that you configured. Make sure to configure the right port for the frontend.
- Modify the
config.js
in./frontend/src/
to match your needs.
cd frontend
npm install
npm start
By default, the frontend will run on port 3000.