Sometimes builds can take quite a while, depending on the project size, dependencies, network speed, general cluster utilization etc. All this time connection opened for git push must stay open which is not very convenient.
It would be nice to have a way to run builds in background. It could work this way:
User sets some option on the app to make deploys async. Maybe an ENV var.
User performs git push
After the push is finished, receive hooks/scripts do not run the build but rather create some kind of background task which performs a build (k8s job?)
The deis command should have some additional subcommand to track the deployment process. It will return the deployment status and exit, so no long-running connections.
It can also have some kind of 'watch' command to connect to the controller and wait for the deploy to finish.
From @ineu on February 2, 2017 12:55
Sometimes builds can take quite a while, depending on the project size, dependencies, network speed, general cluster utilization etc. All this time connection opened for
git push
must stay open which is not very convenient. It would be nice to have a way to run builds in background. It could work this way:git push
deis
command should have some additional subcommand to track the deployment process. It will return the deployment status and exit, so no long-running connections.Another option is to allow to detach from the build process as Heroku does: https://devcenter.heroku.com/articles/git#detach-from-build-process. This approach allows to avoid step 0 above but to me it looks somewhat confusing.
Sorry if this question has been asked before, didn't find it with a quick search.
Copied from original issue: deis/builder#476