You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Added handling for knex-migrator being executed in Ghost 2.0 (#765)
refs #759
- We have moved the execution of knex-migrator into Ghost 2.0.0
- This commit will ensure we skip the db migration when you:
- migrate from ^1 to ^2
- you update from ^2 to ^2
- when you install ^2
- Added net socket server for Ghost 2.0 (alternative to simple port polling)
- way better error handling between Ghost and the CLI
- Ghost 2.0 executes knex-migrator
- it will turn maintenance on if migrations need to be executed
- the handling of receiving success or failure state requires a better communication between the CLI and Ghost, because the blog stays in maintenance mode and runs the migrations in background
- Ghost will tell the CLI when it's ready by using an extension: write a socket url into the config and send the success/failure state
- this is much better than using the http socket to communicate, because
- A) port polling connects to the http port, it's impossible to send simple messages over this transport layer
- B) the code is much simpler, CLI opens a socket port and Ghost pushes a notification if the notification is available
- C) we receive any error from Ghost - even if the http server wasn't started yet
- we don't communicate with Ghost, Ghost communicates with the CLI
- port polling for v1 blogs is untouched, still works as expected
- coverage has decreased a very little 0,2% - will try to add more tests when we merge the 1.9 branch into master
0 commit comments