mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-07-27 02:56:31 +00:00
Fix error on first run because the landing page already run (#886)
* Fix error on first run because the landing page already run * Update homeassistant.py
This commit is contained in:
parent
2b5520405f
commit
a0b5d0b67e
@ -211,15 +211,8 @@ class HomeAssistant(JsonConfig, CoreSysAttributes):
|
|||||||
while True:
|
while True:
|
||||||
if await self.instance.install('landingpage'):
|
if await self.instance.install('landingpage'):
|
||||||
break
|
break
|
||||||
_LOGGER.warning("Fails install landingpage, retry after 60sec")
|
_LOGGER.warning("Fails install landingpage, retry after 30sec")
|
||||||
await asyncio.sleep(60)
|
await asyncio.sleep(30)
|
||||||
|
|
||||||
# Run landingpage after installation
|
|
||||||
_LOGGER.info("Start landing page")
|
|
||||||
try:
|
|
||||||
await self._start()
|
|
||||||
except HomeAssistantError:
|
|
||||||
_LOGGER.warning("Can't start landing page")
|
|
||||||
|
|
||||||
@process_lock
|
@process_lock
|
||||||
async def install(self):
|
async def install(self):
|
||||||
@ -233,8 +226,8 @@ class HomeAssistant(JsonConfig, CoreSysAttributes):
|
|||||||
tag = self.last_version
|
tag = self.last_version
|
||||||
if tag and await self.instance.install(tag):
|
if tag and await self.instance.install(tag):
|
||||||
break
|
break
|
||||||
_LOGGER.warning("Error on install Home Assistant. Retry in 60sec")
|
_LOGGER.warning("Error on install Home Assistant. Retry in 30sec")
|
||||||
await asyncio.sleep(60)
|
await asyncio.sleep(30)
|
||||||
|
|
||||||
# finishing
|
# finishing
|
||||||
_LOGGER.info("Home Assistant docker now installed")
|
_LOGGER.info("Home Assistant docker now installed")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user