Skip to content

Commit

Permalink
included READEME file
Browse files Browse the repository at this point in the history
  • Loading branch information
Hancil committed Mar 16, 2020
1 parent 048a50d commit cd09e1c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1 +1,12 @@
# urlShortening
This code converts the actual url to shortend url and when user clicks on sortend url its redirects to actual url.

# Pre installation
1. Nodejs 8 and above
2. NPM 6 and above
3. Mongo

# Steps to be followed after cloning the project
1. Open the terminal and go till the porject directory and type `npm init`
2. Start the node server using `npm server.js` or `nodemon server.js`

2 changes: 1 addition & 1 deletion server.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ const app = express();
const mongoose = require('mongoose');
const shortUrl = require('./models/urlShortner');

mongoose.connect('mongodb://mongo_docker/UrlShortner', {
mongoose.connect('mongodb://localhost/UrlShortner', {
useUnifiedTopology: true,
useNewUrlParser: true
});
Expand Down

0 comments on commit cd09e1c

Please sign in to comment.