* Bugfix api call

* add log
This commit is contained in:
Pascal Vizeli 2017-05-10 00:00:30 +02:00 committed by GitHub
parent 990ae49608
commit 8919f13911
2 changed files with 4 additions and 0 deletions

View File

@ -78,6 +78,8 @@ class RestAPI(object):
'/addons/{addon}/uninstall', api_addons.uninstall)
self.webapp.router.add_post('/addons/{addon}/start', api_addons.start)
self.webapp.router.add_post('/addons/{addon}/stop', api_addons.stop)
self.webapp.router.add_post(
'/addons/{addon}/restart', api_addons.restart)
self.webapp.router.add_post(
'/addons/{addon}/update', api_addons.update)
self.webapp.router.add_post(

View File

@ -282,6 +282,8 @@ class DockerBase(object):
if not self.container:
return False
_LOGGER.info("Restart %s")
try:
self.container.restart(timeout=30)
except docker.errors.DockerException as err: