Commit c2808f30 authored by w-e-w's avatar w-e-w

SD_WEBUI_RESTARTING

parent eaace155
...@@ -247,7 +247,7 @@ def prepare_environment(): ...@@ -247,7 +247,7 @@ def prepare_environment():
try: try:
# the existance of this file is a signal to webui.sh/bat that webui needs to be restarted when it stops execution # the existance of this file is a signal to webui.sh/bat that webui needs to be restarted when it stops execution
os.remove(os.path.join(script_path, "tmp", "restart")) os.remove(os.path.join(script_path, "tmp", "restart"))
os.environ.setdefault('SD_WEBUI_DISABLE_AUTOLAUNCH', '1') os.environ.setdefault('SD_WEBUI_RESTARTING ', '1')
except OSError: except OSError:
pass pass
......
...@@ -396,7 +396,7 @@ def webui(): ...@@ -396,7 +396,7 @@ def webui():
ssl_verify=cmd_opts.disable_tls_verify, ssl_verify=cmd_opts.disable_tls_verify,
debug=cmd_opts.gradio_debug, debug=cmd_opts.gradio_debug,
auth=gradio_auth_creds, auth=gradio_auth_creds,
inbrowser=cmd_opts.autolaunch and os.getenv('SD_WEBUI_DISABLE_AUTOLAUNCH') != '1', inbrowser=cmd_opts.autolaunch and os.getenv('SD_WEBUI_RESTARTING ') != '1',
prevent_thread_lock=True, prevent_thread_lock=True,
allowed_paths=cmd_opts.gradio_allowed_path, allowed_paths=cmd_opts.gradio_allowed_path,
app_kwargs={ app_kwargs={
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment