commit ce54e9ae156406cfa92a4589e390ce428586eec2
parent d751cd169ff5aea7b33d8b5ee62445dcc9e53379
Author: parazyd <parazyd@dyne.org>
Date: Thu, 15 Apr 2021 22:18:54 +0200
Make the public hostname configurable in the cfg.
Diffstat:
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/res/obelisk.cfg b/res/obelisk.cfg
@@ -3,6 +3,8 @@
# 0.0.0.0 to bind to any IP, 127.0.0.1 to bind to localhost
host = 127.0.0.1
port = 50003
+# Public hostname for the server, ideally a valid domain
+hostname = localhost
# Which chain should this instance of obelisk be using (mainnet/testnet)
chain = testnet
diff --git a/run_obelisk b/run_obelisk
@@ -58,7 +58,7 @@ async def run_electrum_server(config, chain):
endpoints["trans"] = config.get("obelisk", "trans")
server_cfg = {}
- server_cfg["server_hostname"] = "localhost" # TODO: <- should be public?
+ server_cfg["server_hostname"] = config.get("obelisk", "hostname")
server_cfg["server_port"] = port
global PROTOCOL