Spaces:
Running
Running
Update start.py
Browse files
start.py
CHANGED
|
@@ -12,8 +12,14 @@ backend = subprocess.Popen([sys.executable, "-m", "uvicorn", "api.main:app", "--
|
|
| 12 |
print("⏳ [Orchestrator] Waiting 10 seconds for ML models to load...", flush=True)
|
| 13 |
time.sleep(10)
|
| 14 |
|
| 15 |
-
print("🎨 [Orchestrator] Starting Streamlit frontend
|
| 16 |
-
frontend = subprocess.Popen([
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 17 |
|
| 18 |
# Keep the container running by waiting for the frontend process
|
| 19 |
frontend.wait()
|
|
|
|
| 12 |
print("⏳ [Orchestrator] Waiting 10 seconds for ML models to load...", flush=True)
|
| 13 |
time.sleep(10)
|
| 14 |
|
| 15 |
+
print("🎨 [Orchestrator] Starting Streamlit frontend with CORS/XSRF bypassed...", flush=True)
|
| 16 |
+
frontend = subprocess.Popen([
|
| 17 |
+
sys.executable, "-m", "streamlit", "run", "frontend/app.py",
|
| 18 |
+
"--server.port", "7860",
|
| 19 |
+
"--server.address", "0.0.0.0",
|
| 20 |
+
"--server.enableCORS=false",
|
| 21 |
+
"--server.enableXsrfProtection=false"
|
| 22 |
+
])
|
| 23 |
|
| 24 |
# Keep the container running by waiting for the frontend process
|
| 25 |
frontend.wait()
|