DigitalOcean droplet mongo database

Issue

I’m trying to deploy a MERN app, but one thing is unclear to me: Is there a way to set up mongo db without extra payment, for example on droplet that contains the server, and how? I would appreciate it if you could help me understand this a little bit better or point me in the right direction.

Solution

Is there a way to set up mongo db

yes – you either self host or pay for a manged service. In this case you do not want to pay so it is on you to self host the DB server yourself and manage everything such as backup and replication.

To do that you need to

  1. launch a server/VM
  2. Run Mongo on it such as via docker container or the binary itself
  3. Configure firewall rules
  4. Configure backups
  5. Optionally configure High availability if required

Answered By – Asad Awadia

This Answer collected from stackoverflow, is licensed under cc by-sa 2.5 , cc by-sa 3.0 and cc by-sa 4.0

Leave a Reply

(*) Required, Your email will not be published