In Cloud Foundry (the open source technology behind Bluemix), when you do a cf push
, Cloud Foundry will actually stop your app and restart it with the new code that you just uploaded. Â This presents an issue for a production app or any app that is actually serving users. There is a shortcoming with the current DEA (the part in Cloud Foundry that runs your app) but the next version of the DEA (Diego) will help address this. Â In the meantime you can do a little scripting to get around this.
The basic flow is as follows:
- App A is running (prod)
- Deploy App B
- Do some tests against App B
- Map prod route to App B
- Unmap prod route from App A
- Stop App A
- Delete App A
Here is some starter shell code to do it:
|
|