/docker-compose-example

An example app using Node.js, MongoDB and Docker

Primary LanguageJavaScript

Node.js and MongoDB example using docker-compose

To run the app:

  1. Clone this repo
  2. Run docker-compose up --build
  3. Open a shell in the mongo container:
    docker exec -it mongo bash
    mongo
    use test
    db.users.insert({ name: "Your Name", age: "Your Age" })
  4. Exit from the shell by typing exit
  5. Direct your browser to http://localhost:3000