update uri gen to match new config

This commit is contained in:
Arnav Agrawal 2025-01-07 12:43:01 +05:30
parent f72f6f0249
commit bd4d8f8178

View File

@ -33,11 +33,9 @@ payload = {
token = jwt.encode(payload, jwt_secret, algorithm="HS256")
with open("config.toml", "rb") as f:
with open("databridge.toml", "rb") as f:
config = tomli.load(f)
base_url = f"{config['service']['host']}:{config['service']['port']}".replace(
"localhost", "127.0.0.1"
)
base_url = f"{config['api']['host']}:{config['api']['port']}".replace("localhost", "127.0.0.1")
entity_id = args.name
uri = f"databridge://{entity_id}:{token}@{base_url}"