outposts: handle docker connection error on init

This commit is contained in:
Jens Langhammer
2020-10-22 12:49:48 +02:00
parent 8eca76e464
commit 7b5a0964b2
2 changed files with 5 additions and 1 deletions

View File

@ -24,7 +24,10 @@ class DockerController(BaseController):
def __init__(self, outpost: Outpost) -> None:
super().__init__(outpost)
self.client = from_env()
try:
self.client = from_env()
except DockerException as exc:
raise ControllerException from exc
def _get_labels(self) -> Dict[str, str]:
return {}