fixed platform loading

This commit is contained in:
Pünkösd Marcell 2021-11-30 19:53:25 +01:00
parent 8ac5161ad0
commit c07a64d9c8
2 changed files with 4 additions and 2 deletions

View File

@ -33,6 +33,6 @@ API_URL = os.environ.get("API_URL", "http://localhost:8080")
REPORT_URL = os.environ.get("REPORT_URL", None)
REPORT_INTERVAL = float(os.environ.get("REPORT_INTERVAL", 15))
DISABLE_AI = os.environ.get("DISABLE_AI").lower() in ['yes', '1', 'true']
DISABLE_AI = os.environ.get("DISABLE_AI", 'no').lower() in ['yes', '1', 'true']
PLATFORM = os.environ.get("", "raspberry")

View File

@ -1,4 +1,6 @@
from config import PLATFORM
from .config import PLATFORM
print("Loading platform driver:", PLATFORM)
if PLATFORM == 'raspberry':
from birbnetes_iot_platform_raspberry import BirbnetesIoTPlatformStatusDriver, BirbnetesIoTPlatformRecordDriver, \