Skip to content

Latest commit

 

History

History

spawn-mongod

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

spawn-mongod

Spin up a local mongod process.

// Copy data from a collection on the current server to a new server:
> const mongod = spawnMongod({ version: 'latest', port: 27097 })
> mongod.waitReady
listening!
> db.coll.find().forEach(doc => mongod.getDB('test').coll.insertOne(doc))