Skip to content

karan-vk/Node-REST

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

E-commerce RESTful api BY KARAN

Steps to use

  1. use a nodemon.json to set the environment variables MONGO_ATLAS_PW & JWT_KEY

    {
    "env": {
    "MONGO_ATLAS_PW": "YOUR_PASSWORD",
    "JWT_KEY": "YOUR_SECRET"
    }
    }
    
  2. Change the MongoDB uri in app.js

6 mongoose.connect(
7   "mongodb+srv://user:" +
8     process.env.MONGO_ATLAS_PW +
9     "@cluster0.odxd9.gcp.mongodb.net/RestMax?retryWrites=true&w=majority",
10   { useNewUrlParser: true, useUnifiedTopology: true, useCreateIndex: true }
11 );

  1. Create a new folder named upload in the root directory

  2. Run

    npm i
    npm start
    

    The app will start in http://localhost:3000

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published