fix: bind HTTP API to localhost by default and expose --host
This commit is contained in:
@@ -301,7 +301,7 @@ def metrics_dashboard():
|
||||
}), 500
|
||||
|
||||
|
||||
def start_http_server(host='0.0.0.0', port=6060, debug=False):
|
||||
def start_http_server(host='127.0.0.1', port=6060, debug=False):
|
||||
"""启动 HTTP 服务器"""
|
||||
global task_manager, task_scheduler
|
||||
|
||||
@@ -330,4 +330,4 @@ if __name__ == '__main__':
|
||||
format='[%(asctime)s] %(levelname)s: %(message)s'
|
||||
)
|
||||
|
||||
start_http_server(port=6060, debug=True)
|
||||
start_http_server(host='127.0.0.1', port=6060, debug=True)
|
||||
|
||||
Reference in New Issue
Block a user