Skip to content
This repository has been archived by the owner on Jan 3, 2024. It is now read-only.
/ movie-node Public archive

Practice NodeJS application for saving favorite movies into a MongoDB with Mongoose

Notifications You must be signed in to change notification settings

ChristianKomodo/movie-node

Repository files navigation

Movie Node

Example movie database project using Node/Express, MongoDB and Mongoose

Installation

Clone it, then get your dependencies with npm install like usual.

Then create an .env file on the root and populate it with your MongoDB connection string in one of two ways:

Using a local Mongo database

DB_HOST="localhost:27017/movie-node";

Using mLab.com

DB_HOST="mongodb://<dbuser>:<dbpassword>@ds119650.mlab.com:19650/movie-node"

(Substitute your database username and password)

The package dotenv has already been installed and will allow you to access that .env file.

Run the project

Then start the server with npm start

The main page will have a form to add your favorite movies, and also display all the added movies in the database so far.

localhost:3000

If this is your first time running the appliaction, you can add two entries into the database by hitting the following URL:

localhost:3000/movies/make

About

Practice NodeJS application for saving favorite movies into a MongoDB with Mongoose

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published