Skip to content

Commit e49a5ed

Browse files
committed
Changed default host to 0.0.0.0 and port to 5000
1 parent 2cc63fe commit e49a5ed

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

adafruit_httpserver/server.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ def _verify_can_start(self, host: str, port: int) -> None:
171171
raise RuntimeError(f"Cannot start server on {host}:{port}") from error
172172

173173
def serve_forever(
174-
self, host: str, port: int = 80, *, poll_interval: float = 0.1
174+
self, host: str = "0.0.0.0", port: int = 5000, *, poll_interval: float = 0.1
175175
) -> None:
176176
"""
177177
Wait for HTTP requests at the given host and port. Does not return.
@@ -212,7 +212,7 @@ def _create_server_socket(
212212

213213
return sock
214214

215-
def start(self, host: str, port: int = 80) -> None:
215+
def start(self, host: str = "0.0.0.0", port: int = 5000) -> None:
216216
"""
217217
Start the HTTP server at the given host and port. Requires calling
218218
``.poll()`` in a while loop to handle incoming requests.

0 commit comments

Comments
 (0)