MongoDB driver plugin for db-migrate, enabling database migrations for MongoDB databases. Current stable version 1.5.0, maintained as part of the db-migrate ecosystem. Provides seamless integration with db-migrate's migration framework, supporting up/down migrations, seed data, and configuration via database.json. Automatically uses the mongodb native driver version 3.x (ships its own dependency). Compared to manual migration scripts, it offers a structured, version-controlled approach with rollback support.
npm install db-migrate-mongodbNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows configuration and a sample migration creating and dropping a users collection.
Ensure db-migrate and db-migrate-base are installed alongside this package.
Remove any explicit require/import of this package from migration scripts.
Use callback-based API in migration up/down functions; avoid returning promises.
npm install db-migrate db-migrate-base
Make sure exports.setup is called correctly; use the `db` parameter provided in up/down functions.
Check MongoDB driver documentation for the correct method signature, especially for insert/update operations.