Skip to content
This repository was archived by the owner on Nov 1, 2023. It is now read-only.

ct0r/node-migrate-mongodb

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

node-migrate-mongodb

Version Build Coverage License

Mongo store for node-migrate.

Installation

npm install node-migrate-mongodb

Options

Command line Programmatic Description
--store-url url Mongo url. Default mongodb://localhost:27017.
--store-collection collection Collection name. Default _migrations.

Usage

Command line

node-migrate --store node-migrate-mongodb --store-url mongodb://my-server/my-db --store-collection my_migrations

Programatic use

const migrate = require('node-migrate');
const mongoStore = require('node-migrate-mongodb');

const store = mongoStore({
  url: 'mongodb://my-server/my-db',
  collection: 'my_migrations'
});

migrate({ store });

About

Mongo store for node-migrate

Resources

License

Stars

Watchers

Forks

Packages

No packages published