// To help improve our products, anonymous usage data is collected and sent to MongoDB periodically (https://www.mongodb.com/legal/privacy-policy). // You can opt-out by running the disableTelemetry() command. disableTelemetry() // Create the DB by inserting some data db.v0.insertOne({init_key: "init_data"}) // Create user db.createUser( { user: "REPLACE_USERNAME", pwd: "REPLACE_PASSWORD", roles: [ { role: "readWrite", db: "production" } ] } ) // Delete the init data db.v0.deleteOne({init_key: "init_data"}) // Disable the ad about monitoring db.disableFreeMonitoring() // Restart server now db.shutdownServer()