Code Monkey home page Code Monkey logo

prethesis's Introduction

Prethesis

This repository contains the source code for the MERN stack project developed as part of my thesis.

Getting Started

Follow these steps to set up the project for local development:

  1. Clone the repository:

git clone https://github.com/anhtuan00/prethesis.git

  1. Open the cloned repository in Visual Studio Code.

  2. Set up the .env file in the backend folder:

MONGO_URL="Your mongo url" JWT_SECRET="Your jwt secret" JWT_LIFETIME="Your jwt lifetime"

  1. Install dependencies in the backend folder:

cd backend yarn install cd ..

  1. Install dependencies in the frontend folder:

cd frontend yarn install cd ..

  1. Install dependencies in the root folder:

yarn install

  1. Start the project:

yarn run start

Now, the project should be running at http://localhost:3000.

Deployment on Render

Follow these steps to deploy your project on Render:

  1. Sign up for an account at https://render.com/ if you don't have one already.

  2. Create a new Web Service by clicking on the "New" button at the top right corner of Render Dashboard and selecting "Web Service".

  3. Choose "GitHub" or "GitLab" as your repository provider and authorize Render to access your repositories.

  4. Select the repository containing your project (e.g., the repository you forked from the original repo).

  5. Configure the Web Service:

    • Name: Set the name for the service (e.g., "your-project").
    • Branch: Select the main branch.
    • Runtime: Choose "Node".
    • Root Directory: Set the root directory to backend.
    • Build Command: Set the build command to yarn pre-deploy.
    • Start Command: Set the start command to yarn deploy.
  6. Configure environment variables and secret files:

    • Click on the "Environment" tab.
    • Add the following environment variables:
      • MONGO_URL: Set this to your MongoDB connection string.
      • JWT_SECRET: Set this to your JWT secret.
      • JWT_LIFETIME: Set this to your JWT lifetime.
    • Click on the "Secret Files" tab.
    • Click on "Add Secret File".
    • Set the Filename to .env.
    • Copy the contents of your local .env file into the Content field.
  7. Click "Create" to deploy your service.

prethesis's People

Contributors

anhtuan00 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.