hardcode port

This commit is contained in:
Jeffrey Picard 2021-06-23 17:28:32 -04:00 committed by Victor Shyba
parent 4544a074d9
commit 8e5b4d4b6f

View file

@ -2611,15 +2611,13 @@ class Daemon(metaclass=JSONRPCServerType):
Returns: {Paginated[Output]} Returns: {Paginated[Output]}
""" """
# if os.environ.get("GO_HUB") and os.environ.get("GO_HUB") == "true":
if self.ledger.config['use_go_hub']: if self.ledger.config['use_go_hub']:
if self.ledger.config['first_search']: if self.ledger.config['first_search']:
# Only do this the first time because we might need to retry due to the go hub not being there # Only do this the first time because we might need to retry due to the go hub not being there
self.ledger.config['first_search'] = False self.ledger.config['first_search'] = False
kwargs_old = copy.copy(kwargs) kwargs_old = copy.copy(kwargs)
host = self.ledger.network.client.server[0] host = self.ledger.network.client.server[0]
# host = os.environ.get("HUB_HOST", "localhost") port = "50051"
port = os.environ.get("HUB_PORT", "50051")
kwargs['new_sdk_server'] = f"{host}:{port}" kwargs['new_sdk_server'] = f"{host}:{port}"
if kwargs.get("channel"): if kwargs.get("channel"):
channel = kwargs.pop("channel") channel = kwargs.pop("channel")