Merge branch 'master' into abidlabs/url

This commit is contained in:
Abubakar Abid 2021-12-14 20:40:51 -06:00
commit 13b3508a00

View File

@ -430,7 +430,8 @@ def start_server(interface, server_name, server_port, auth=None, ssl=None):
port = get_first_available_port(
server_port, server_port + TRY_NUM_PORTS
)
path_to_local_server = "http://{}:{}/".format(server_name, port)
url_host_name = "localhost" if server_name == "0.0.0.0" else server_name
path_to_local_server = "http://{}:{}/".format(url_host_name, port)
if auth is not None:
if not callable(auth):
app.auth = {account[0]: account[1] for account in auth}