Start the local browser GUI.
(
host: str = typer.Option("127.0.0.1", "--host", help="Host interface for the local GUI server."),
port: int = typer.Option(8765, "--port", "-p", help="Port for the local GUI server."),
no_browser: bool = typer.Option(False, "--no-browser", help="Do not open the browser automatically."),
)
| 229 | |
| 230 | @app.command() |
| 231 | def gui( |
| 232 | host: str = typer.Option("127.0.0.1", "--host", help="Host interface for the local GUI server."), |
| 233 | port: int = typer.Option(8765, "--port", "-p", help="Port for the local GUI server."), |
| 234 | no_browser: bool = typer.Option(False, "--no-browser", help="Do not open the browser automatically."), |
| 235 | allow_remote: bool = typer.Option( |
| 236 | False, |
| 237 | "--allow-remote", |
| 238 | help="Permit binding a non-loopback host. The GUI is unauthenticated and its " |
| 239 | "settings endpoint can rewrite .env, so only use this on a trusted network.", |
| 240 | ), |
| 241 | ) -> None: |
| 242 | """Start the local browser GUI.""" |
| 243 | script = PROJECT_ROOT / "deployments" / "desktop" / "server.py" |
| 244 | if not script.exists(): |
| 245 | typer.echo(f"[error] desktop GUI server not found: {script}", err=True) |
| 246 | raise typer.Exit(code=1) |
| 247 | args = ["--host", host, "--port", str(port)] |
nothing calls this directly
no test coverage detected