12/13/2021

docker MongoDB pull and run

 

#pull image

docker pull mongodb

#run container

docker run --name mongodb -d -p 27017:27017 mongo


ex) access in python 

import pymongo # package for working with MongoDB
client = pymongo.MongoClient("mongodb://localhost:27017/")


Thank you.

www.marearts.com