mysqldump-stream
v1.0.1
Published
Implementation of unix utility mysqldump
Downloads
97
Maintainers
Readme
mysqldump
Node.js implementation of mysqldump
utility based on Readable
stream.
Install
npm install mysqldump-stream
Usage
var Mysqldump = require('mysqldump-stream');
var mysqldump = new Mysqldump('mydatabase', {
gzip: true, //default: false
host: 'localhost', //default
port: 3306, //default
user: 'root', //default: process.env.USER || 'root'
password: 'mypassword' //default: false
});
var fs = require('fs');
mysqldump.start();
mysqldump.pipe(fs.createWriteStream('./mydatabase.sql.gz'));