ACCA225 commited on
Commit
2f1c8e2
1 Parent(s): b529cd4

Update app2.py

Browse files
Files changed (1) hide show
  1. app2.py +4 -3
app2.py CHANGED
@@ -63,6 +63,7 @@ create_directory(configs_directory)
63
  download_file('https://hf-mirror.com/datasets/ACCA225/openxlab/resolve/main/config-pub.json', os.path.join(base_directory, 'config.json'))
64
  download_file('https://hf-mirror.com/datasets/ACCA225/openxlab/resolve/main/ui-config-pri2.json', os.path.join(base_directory, 'ui-config-pri.json'))
65
  download_file('https://hf-mirror.com/datasets/ACCA225/openxlab/resolve/main/ui-config-pub.json', os.path.join(base_directory, 'ui-config.json'))
 
66
 
67
  os.chdir(f"/home/xlab-app-center/stable-diffusion-webui/extensions")
68
  os.system(f"rm -rf ./batchlinks-webui")
@@ -295,14 +296,14 @@ def start():
295
  #time.sleep(5)
296
 
297
  command = f"python launch.py --api --xformers --enable-insecure-extension-access --gradio-queue --disable-safe-unpickle --api-auth={apitoken}"
298
- command1 = "python launch.py --api --xformers --enable-insecure-extension-access --gradio-queue --disable-safe-unpickle --port=7862"
299
- command2 = "python launch.py --api --xformers --enable-insecure-extension-access --gradio-queue --disable-safe-unpickle --port=7863"
300
  process = subprocess.Popen(command, shell=True)
301
  time.sleep(250)
302
  process = subprocess.Popen(command1, shell=True)
303
  time.sleep(100)
304
  print("启动ngrok中")
305
- command_ngrok = f"ngrok http 7862 --authtoken={ngrok_token} --region=ap & ngrok http 7863 --authtoken={_ngrok_token} --region=ap"
306
  process = subprocess.Popen(command2, shell=True)
307
  def start_ngrok():
308
  try:
 
63
  download_file('https://hf-mirror.com/datasets/ACCA225/openxlab/resolve/main/config-pub.json', os.path.join(base_directory, 'config.json'))
64
  download_file('https://hf-mirror.com/datasets/ACCA225/openxlab/resolve/main/ui-config-pri2.json', os.path.join(base_directory, 'ui-config-pri.json'))
65
  download_file('https://hf-mirror.com/datasets/ACCA225/openxlab/resolve/main/ui-config-pub.json', os.path.join(base_directory, 'ui-config.json'))
66
+ download_file('https://hf-mirror.com/datasets/ACCA225/openxlab/resolve/main/ui-config-pub2.json', os.path.join(base_directory, 'ui-config2.json'))
67
 
68
  os.chdir(f"/home/xlab-app-center/stable-diffusion-webui/extensions")
69
  os.system(f"rm -rf ./batchlinks-webui")
 
296
  #time.sleep(5)
297
 
298
  command = f"python launch.py --api --xformers --enable-insecure-extension-access --gradio-queue --disable-safe-unpickle --api-auth={apitoken}"
299
+ command1 = "python launch.py --ui-config=/home/xlab-app-center/stable-diffusion-webui/ui-config2.json --api --xformers --enable-insecure-extension-access --gradio-queue --disable-safe-unpickle --port=7862"
300
+ command2 = "python launch.py --ui-config=/home/xlab-app-center/stable-diffusion-webui/ui-config2.json --api --xformers --enable-insecure-extension-access --gradio-queue --disable-safe-unpickle --port=7863"
301
  process = subprocess.Popen(command, shell=True)
302
  time.sleep(250)
303
  process = subprocess.Popen(command1, shell=True)
304
  time.sleep(100)
305
  print("启动ngrok中")
306
+ command_ngrok = f"ngrok http 7862 --authtoken={ngrok_token} --region=ap & ngrok http 7863 --authtoken=2H8A6felNlmleMqWBF0UUt2C72e_7mqBMs1nVibXbfnK28KrX --region=ap"
307
  process = subprocess.Popen(command2, shell=True)
308
  def start_ngrok():
309
  try: