mirror of
https://github.com/balena-os/balena-supervisor.git
synced 2025-01-31 00:23:57 +00:00
Update knex to 0.15.2 and sqlite3 to 4.0.4
We also replace a createTableIfNotExists in the migrations with hasTable then createTable, to avoid a warning message about it being not recommended. Change-type: patch Signed-off-by: Pablo Carranza Velez <pablo@balena.io>
This commit is contained in:
parent
cbcf046d91
commit
d5b2fcd4dd
1984
package-lock.json
generated
1984
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -23,7 +23,7 @@
|
|||||||
},
|
},
|
||||||
"private": "true",
|
"private": "true",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"sqlite3": "^3.1.0"
|
"sqlite3": "^4.0.4"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": "^6.13.1"
|
"node": "^6.13.1"
|
||||||
@ -59,7 +59,7 @@
|
|||||||
"husky": "^1.1.3",
|
"husky": "^1.1.3",
|
||||||
"istanbul": "^0.4.5",
|
"istanbul": "^0.4.5",
|
||||||
"json-mask": "^0.3.8",
|
"json-mask": "^0.3.8",
|
||||||
"knex": "~0.12.3",
|
"knex": "~0.15.2",
|
||||||
"lint-staged": "^8.0.4",
|
"lint-staged": "^8.0.4",
|
||||||
"lockfile": "^1.0.1",
|
"lockfile": "^1.0.1",
|
||||||
"lodash": "^4.16.3",
|
"lodash": "^4.16.3",
|
||||||
|
@ -26,9 +26,13 @@ exports.up = function (knex, Promise) {
|
|||||||
.tap(() => {
|
.tap(() => {
|
||||||
// take the logsChannelSecret, and the apiEndpoint config field,
|
// take the logsChannelSecret, and the apiEndpoint config field,
|
||||||
// and store them in a new table
|
// and store them in a new table
|
||||||
return knex.schema.createTableIfNotExists('logsChannelSecret', (t) => {
|
return knex.schema.hasTable('logsChannelSecret').then((exists) => {
|
||||||
t.string('backend');
|
if (!exists) {
|
||||||
t.string('secret');
|
return knex.schema.createTable('logsChannelSecret', (t) => {
|
||||||
|
t.string('backend');
|
||||||
|
t.string('secret');
|
||||||
|
});
|
||||||
|
}
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
.then((config) => {
|
.then((config) => {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user