/config/config.local.js
"use strict";
exports.sequelize = {
dialect: "mysql",
host: "0.0.0.0",
port: 3306,
database: "name",
username: "user",
password: "password",
};
/config/config.prod.js
"use strict";
exports.sequelize = {
dialect: "mysql",
host: "0.0.0.0",
port: 3306,
database: "name",
username: "user",
password: "password",
};
/database/cofig.json
用于migration连接数据库
{
"development": {
"dialect": "mysql",
"host": "0.0.0.0",
"port": 3306,
"database": "name",
"username": "user",
"password": "password"
}
}
$ npm i
$ npm run dev
$ open http://localhost:7001/
$ npm start
$ npm stop