backend/data/db.js

9 lines
241 B
JavaScript
Raw Normal View History

2020-05-02 19:06:34 +00:00
const knex = require('knex');
const knexfile = require('../knexfile');
const { environment} = require('../config/config')
2020-05-02 19:06:34 +00:00
const env = environment || 'development';
2020-05-02 19:06:34 +00:00
const configOptions = knexfile[env];
module.exports = knex(configOptions);