diff options
Diffstat (limited to 'db/db.js')
| -rw-r--r-- | db/db.js | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/db/db.js b/db/db.js new file mode 100644 index 00000000..914d049f --- /dev/null +++ b/db/db.js @@ -0,0 +1,17 @@ +import Sequelize from '@sequelize/core'; +import dbOptions from '../config/knexfile.js'; + +let { database, user, password, host } = dbOptions[process.env.NODE_ENV].connection; + +export default new Sequelize( + database, + user, + password, + { + host, + dialect: "mariadb", + logging: false, + dialectOptions: { multipleStatements: true, timezone: "Etc/GMT+7" }, + } +); + |
