Files
Atomizer/dashboard/start_dashboard.py
Anto01 c1fad3bd37 fix: Change dashboard port from 5000 to 8080 to avoid Siemens conflict
- Update Flask server to run on port 8080 instead of 5000
- Update frontend API_BASE URL to http://localhost:8080/api
- Update launcher script to open browser at port 8080
- Update README documentation with new port number

This resolves the port conflict with Siemens documentation server.
2025-11-15 13:41:21 -05:00

46 lines
1.1 KiB
Python

"""
Atomizer Dashboard Launcher
Simple script to start the dashboard server and open the browser.
"""
import sys
import webbrowser
import time
from pathlib import Path
import subprocess
def main():
dashboard_dir = Path(__file__).parent
api_script = dashboard_dir / 'api' / 'app.py'
print("="*60)
print("ATOMIZER DASHBOARD LAUNCHER")
print("="*60)
print(f"\nStarting dashboard server...")
print(f"Dashboard will open at: http://localhost:8080")
print("\nPress Ctrl+C to stop the server")
print("="*60)
# Give user a moment to read
time.sleep(2)
# Open browser after a short delay
def open_browser():
time.sleep(3) # Wait for server to start
webbrowser.open('http://localhost:8080')
import threading
browser_thread = threading.Thread(target=open_browser, daemon=True)
browser_thread.start()
# Start the Flask server
try:
subprocess.run([sys.executable, str(api_script)], cwd=str(dashboard_dir))
except KeyboardInterrupt:
print("\n\nShutting down dashboard server...")
print("Goodbye!")
if __name__ == '__main__':
main()