feat: add --http-host flag for custom bind address#115
Open
r33drichards wants to merge 1 commit intomainfrom
Open
feat: add --http-host flag for custom bind address#115r33drichards wants to merge 1 commit intomainfrom
r33drichards wants to merge 1 commit intomainfrom
Conversation
e23fff3 to
8e15c85
Compare
MCP-V8 Load Test Benchmark ReportComparison of single-node vs 3-node cluster at various request rates. Results
P95 Latency
Notes
|
Adds --http-host (short: --host, -h) CLI argument to allow binding the HTTP server to a specific network interface instead of the default 0.0.0.0. Usage: server --http-port 3456 --http-host 127.0.0.1 # long form server --http-port 3456 --host 127.0.0.1 # alias server --http-port 3456 -h 127.0.0.1 # short form server --http-port 3456 # default: 0.0.0.0 This enables use cases like: - Binding to localhost for security (only local access) - Binding to a specific interface IP for network segmentation - Binding to a dummy interface for subnet router scenarios
8e15c85 to
2990cb8
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
--http-hostCLI argument to allow binding the HTTP server to a specific network interface instead of the default0.0.0.0(all interfaces).Changes
--http-hostCLI argument (default:0.0.0.0)start_streamable_http()function signature to accepthostparameterformat!("{}:{}", host, port)Usage
Use Cases
127.0.0.1to prevent external accessTesting
Code compiles successfully (requires openssl-dev for full build). Changes are minimal and follow existing patterns in the codebase.
Backward Compatibility
✅ Fully backward compatible - defaults to
0.0.0.0(existing behavior) when--http-hostis not specified.