From 4f0c990601beee15e4c334271982f2ed50855390 Mon Sep 17 00:00:00 2001 From: Santiago Lo Coco Date: Fri, 25 Oct 2024 22:09:10 +0200 Subject: [PATCH] Update db.py --- src/db.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/db.py b/src/db.py index 7408768..4760002 100644 --- a/src/db.py +++ b/src/db.py @@ -1,5 +1,7 @@ from flask_sqlalchemy import SQLAlchemy +from config import API_HOST + db = SQLAlchemy() @@ -19,8 +21,8 @@ def init_default_endpoints(): existing_endpoints = {endpoint.id for endpoint in Endpoint.query.all()} default_endpoints = [ - Endpoint(id=1, url="http://windows.local:8100/mystream/"), - Endpoint(id=2, url="http://windows.local:8200/mystream/"), + Endpoint(id=1, url=f"http://{API_HOST}:8100/mystream/"), + Endpoint(id=2, url=f"http://{API_HOST}:8200/mystream/"), ] updated = False