brew install mongo
Create database directory
sudo mkdir -p /data/db
Find your username
whoami
Taking ownership to /data/db
// assume your username is John
sudo chown -Rv John /data/db
mongod
If you don't want to run mongod everytime you need, the following command will automatically start your database while the computer is running:
brew services start mongo
npm install
npm run dev
npm run build
npm start