This is known as a blue-green deployment, and there are several plug-ins for cloud showers that will do this automatically:
Bluemix Active Deployment Service
, - . , Bluemix . cf , :
cf add-plugin-repo bluemix http:
cf install-plugin active-deploy -r bluemix
( cf ), ,
cf push
cf active-deploy-create old-version new-version
Cloud Foundry -
, cf add-plugin-repo garage https://garage-cf-plugins.eu-gb.mybluemix.net/ cf install-plugin blue-green-deploy -r
, ,
cf blue-green-deploy app_name --smoke-test <path to test script>
smoke test , .