mirror of
https://github.com/balena-os/balena-supervisor.git
synced 2025-02-22 18:22:41 +00:00
Auto-merge for PR #599 via VersionBot
Remove any leftover knex migrations locks before running migrations
This commit is contained in:
commit
11e8899455
@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file
|
|||||||
automatically by Versionist. DO NOT EDIT THIS FILE MANUALLY!
|
automatically by Versionist. DO NOT EDIT THIS FILE MANUALLY!
|
||||||
This project adheres to [Semantic Versioning](http://semver.org/).
|
This project adheres to [Semantic Versioning](http://semver.org/).
|
||||||
|
|
||||||
|
## v7.1.19 - 2018-03-22
|
||||||
|
|
||||||
|
* Remove any leftover knex migrations locks before running migrations #599 [Pablo Carranza Velez]
|
||||||
|
|
||||||
## v7.1.18 - 2018-03-19
|
## v7.1.18 - 2018-03-19
|
||||||
|
|
||||||
* Trim whitespace from the hostname file on the host before passing it as the hostname for containers with host network #595 [Pablo Carranza Velez]
|
* Trim whitespace from the hostname file on the host before passing it as the hostname for containers with host network #595 [Pablo Carranza Velez]
|
||||||
|
@ -6,5 +6,8 @@ module.exports = {
|
|||||||
connection: {
|
connection: {
|
||||||
filename: './database.sqlite'
|
filename: './database.sqlite'
|
||||||
},
|
},
|
||||||
useNullAsDefault: true
|
useNullAsDefault: true,
|
||||||
|
migrations: {
|
||||||
|
directory: './src/migrations'
|
||||||
|
}
|
||||||
}
|
}
|
@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "resin-supervisor",
|
"name": "resin-supervisor",
|
||||||
"description": "This is resin.io's Supervisor, a program that runs on IoT devices and has the task of running user Apps (which are Docker containers), and updating them as Resin's API informs it to.",
|
"description": "This is resin.io's Supervisor, a program that runs on IoT devices and has the task of running user Apps (which are Docker containers), and updating them as Resin's API informs it to.",
|
||||||
"version": "7.1.18",
|
"version": "7.1.19",
|
||||||
"license": "Apache-2.0",
|
"license": "Apache-2.0",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
@ -13,6 +13,9 @@ module.exports = class DB
|
|||||||
)
|
)
|
||||||
|
|
||||||
init: =>
|
init: =>
|
||||||
|
@knex('knex_migrations_lock').update({ is_locked: 0 })
|
||||||
|
.catch(->) # Knex doesn't return a bluebird promise here so we can't catchReturn :(
|
||||||
|
.then =>
|
||||||
@knex.migrate.latest(directory: path.join(__dirname, 'migrations'))
|
@knex.migrate.latest(directory: path.join(__dirname, 'migrations'))
|
||||||
|
|
||||||
# Returns a knex object for one of the models (tables)
|
# Returns a knex object for one of the models (tables)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user