Skip to content

serve: bind to localhost by default (#706)#722

Open
Matir wants to merge 4 commits into
OpenHands:mainfrom
Matir:servebind
Open

serve: bind to localhost by default (#706)#722
Matir wants to merge 4 commits into
OpenHands:mainfrom
Matir:servebind

Conversation

@Matir
Copy link
Copy Markdown

@Matir Matir commented May 7, 2026

This defaults to having the docker container for the openhands server bind to localhost only, but also provides a flag that allows for the user to select any host/port to bind to:

# bind to all interfaces, port 8888
openhands server --bind=0.0.0.0:8888

# bind to all interfaces, port 3000 (default)
openhands server --bind=0.0.0.0

# bind to loopback, port 8888
openhands server --bind=127.0.0.1:8888

Tests:

make lint
Checking uv version...
uv version 0.11.10 meets requirements
Linting code with uv format...
uv run ruff check openhands_cli/ --fix
All checks passed!
Code linted successfully.

make test
(... output elided)
==================================== 1322 passed in 60.41s (0:01:00) =====================================
Tests completed.

@Matir
Copy link
Copy Markdown
Author

Matir commented May 8, 2026

This will fix the security issue in #706 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant