fixup! adding ha addon support
This commit is contained in:
parent
96b91f85a2
commit
e69e10de27
@ -15,6 +15,8 @@ async function run() {
|
||||
}
|
||||
HA_MIDDLEWARE = await HAMiddleware.getInstance({
|
||||
host: 'supervisor',
|
||||
port: 80,
|
||||
path: '/core/websocket',
|
||||
token,
|
||||
});
|
||||
BRIDGE = getBridge();
|
||||
@ -22,7 +24,11 @@ async function run() {
|
||||
BRIDGE.start();
|
||||
}
|
||||
|
||||
run().then().catch(LOGGER.error);
|
||||
run()
|
||||
.then()
|
||||
.catch((error) => {
|
||||
LOGGER.error(JSON.stringify(error));
|
||||
});
|
||||
|
||||
process.on('SIGINT', () => {
|
||||
HA_MIDDLEWARE.stop();
|
||||
|
Loading…
Reference in New Issue
Block a user