* Revert "Migration sql changes (#199)"
This reverts commit 12c834469c.
* Save migrate file on db
* Add message on migration error in lamassu-update
18 lines
284 B
JavaScript
18 lines
284 B
JavaScript
var db = require('./db')
|
|
|
|
exports.up = function (next) {
|
|
const sql =
|
|
[`create table logs (
|
|
id uuid PRIMARY KEY,
|
|
device_id text,
|
|
log_level text,
|
|
timestamp timestamptz,
|
|
message text)`
|
|
]
|
|
|
|
db.multi(sql, next)
|
|
}
|
|
|
|
exports.down = function (next) {
|
|
next()
|
|
}
|