0.0.3 • Published 11 months ago
sequelize-mysql-ssh v0.0.3
Description
Here's the translation of your previous message:
Sequelize
usescloneDeep
in the configuration, which causes somestream
to be unreadable.- After initialization,
Sequelize
does not provide a method to passstream
during subsequent execution.
Therefore, we made some small changes to the Sequelize
source code.
Install
Using npm:
npm install sequelize-mysql-ssh
Or using yarn:
yarn add sequelize-mysql-ssh
Usage
const config = {
host: "", //数据库远程地址
username: "", //数据库用户名
database: "", //数据库
password: "", //数据库密码
dialect: "mysql",
ssh: {
host: "", //远程主机地址
port: 22, //主机端口
username: "", //主机用户名
password: "", //主机密码
},
};
const sequelize = new Sequelize(config);
sequelize.query("select * from table").then((data) => {
console.log("=====>", data);
});
MIT License
Copyright (c) 2014-present Sequelize contributors