mirror of
https://github.com/ParisNeo/lollms-webui.git
synced 2025-01-30 08:03:57 +00:00
fixed remote access
This commit is contained in:
parent
5f93989bdd
commit
20d8886c36
4
app.py
4
app.py
@ -79,9 +79,9 @@ if __name__ == "__main__":
|
||||
# Create a Socket.IO server
|
||||
if config["host"]!="localhost":
|
||||
if config["host"]!="0.0.0.0":
|
||||
config.allowed_origins += config["host"]
|
||||
config.allowed_origins.append(f"https://{config['host']}:{config['port']}" if is_https else f"http://{config['host']}:{config['port']}")
|
||||
else:
|
||||
config.allowed_origins += get_ip_addresses()
|
||||
config.allowed_origins += [f"https://{ip}:{config['port']}" if is_https else f"http://{ip}:{config['port']}" for ip in get_ip_addresses()]
|
||||
allowed_origins = config.allowed_origins+[f"https://localhost:{config['port']}" if is_https else f"http://localhost:{config['port']}"]
|
||||
sio = socketio.AsyncServer(async_mode="asgi", cors_allowed_origins=allowed_origins, ping_timeout=1200, ping_interval=30) # Enable CORS for selected origins
|
||||
|
||||
|
@ -1 +1 @@
|
||||
Subproject commit c7abab41eee0941b15a05e88f3dfe0d006e47489
|
||||
Subproject commit 5989ddbc7cd1e2a85934adbb522fce917c0a98a1
|
@ -1 +1 @@
|
||||
Subproject commit 715f5c8dff08adaee16376ef19252eef79cec00e
|
||||
Subproject commit 62b9c546de5542090ab2cf2d1cf47d7e742dedcb
|
Loading…
x
Reference in New Issue
Block a user