summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcin Juszkiewicz <marcin@juszkiewicz.com.pl>2018-11-21 10:28:05 +0100
committerJon Schlueter <jschluet@redhat.com>2019-01-31 10:48:20 -0500
commit63e5e4d65895616cce29d73e4cf08a876a6db83e (patch)
tree6829a05ef42b0a868bc4370ded4d16bb57b9e5d5
parent7526cf4d6765b9950f4f5297bbd7d72f2150c4f4 (diff)
build: exit if there is no Docker connection
When user starts Kolla on system without Docker daemon running huge traceback is generated and then exit. Issue is because KollaWorker raises exception but no one catches it (then only call to it is in run_build() which assumes everything is ok). Change-Id: I68ea3f48c75b51dbbab3accbc531d2f73428c48f
Notes
Notes (review): Code-Review+2: Mark Goddard <mark@stackhpc.com> Code-Review+1: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org> Code-Review+2: Martin André <m.andre@redhat.com> Workflow+1: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org> Code-Review+1: Michal Nasiadka <michal.nasiadka@nokia.com> Code-Review+2: Surya Prakash (spsurya) <singh.surya64mnnit@gmail.com> Workflow+1: Surya Prakash (spsurya) <singh.surya64mnnit@gmail.com> Verified+2: Zuul Submitted-by: Zuul Submitted-at: Wed, 06 Feb 2019 07:45:53 +0000 Reviewed-on: https://review.openstack.org/619185 Project: openstack/kolla Branch: refs/heads/master
-rwxr-xr-xkolla/image/build.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/kolla/image/build.py b/kolla/image/build.py
index 8e136b4..eb5512d 100755
--- a/kolla/image/build.py
+++ b/kolla/image/build.py
@@ -744,7 +744,9 @@ class KollaWorker(object):
744 or conf.save_dependency 744 or conf.save_dependency
745 or conf.list_images 745 or conf.list_images
746 or conf.list_dependencies): 746 or conf.list_dependencies):
747 raise e 747 LOG.error("Unable to connect to Docker, exiting")
748 LOG.info("Exception caught: {0}".format(e))
749 sys.exit(1)
748 750
749 def _get_images_dir(self): 751 def _get_images_dir(self):
750 possible_paths = ( 752 possible_paths = (