lib/vidar/cli.rb in vidar-1.4.2 vs lib/vidar/cli.rb in vidar-1.4.3
- old
+ new
@@ -82,9 +82,10 @@
Run.kubectl "delete job deploy-hook --ignore-not-found=true"
Run.kubectl "set image cronjobs/deploy-hook-template deploy-hook-template=#{Config.get!(:image)}:#{revision} --all"
Run.kubectl "create job deploy-hook --from=#{template_name}"
deploy_status = Vidar::DeployStatus.new(namespace: Config.get!(:namespace), filter: "deploy-hook")
+ deploy_status.wait_until_up
deploy_status.wait_until_completed
unless deploy_status.success?
Run.kubectl "describe job deploy-hook"
Log.error "Error running deploy hook template"