File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change 3333TIMEOUT_OUTPUT = (
3434 "The script's running time exceeded the limit and the execution was aborted."
3535)
36+ HOST = os .environ .get ("PYTHON_SCHEDULER_BIND_HOST" , "127.0.0.1" )
3637
3738app = Flask (__name__ )
3839
@@ -373,6 +374,5 @@ def base_run_python_statistics():
373374
374375
375376if __name__ == "__main__" :
376- scheduler .start ()
377- http_server = WSGIServer (("0.0.0.0" , 5055 ), app )
377+ http_server = WSGIServer ((HOST , 5055 ), app )
378378 http_server .serve_forever ()
Original file line number Diff line number Diff line change 7171SEATABLE_USER_UID = 1000
7272SEATABLE_USER_GID = 1000
7373
74+ # bind host
75+ HOST = os .environ .get ("PYTHON_STARTER_BIND_HOST" , "127.0.0.1" )
76+
7477
7578def get_log_level (level ):
7679 if level .lower () == "info" :
@@ -474,4 +477,4 @@ def health_check():
474477
475478
476479if __name__ == "__main__" :
477- app .run (host = "0.0.0.0" , port = 8088 , debug = False )
480+ app .run (host = HOST , port = 8088 , debug = False )
You can’t perform that action at this time.
0 commit comments