@@ -15,6 +15,10 @@ When you install an MCP server in ToolHive, you choose how the server reaches
1515the network. _ Network isolation_ routes the server's outbound HTTP and HTTPS
1616traffic through an egress proxy that restricts it to the destinations you allow.
1717
18+ By default, ToolHive enables network isolation for local MCP servers, matching
19+ the ToolHive CLI. New servers start behind the HTTP proxy, and you can relax or
20+ tighten this from the ** Network access** tab as described below.
21+
1822:::note
1923
2024Network isolation supports HTTP and HTTPS connections only. Other protocols are
@@ -54,9 +58,10 @@ configuration form and choose one of three modes:
5458 is routed through ToolHive's egress proxy, which only forwards connections to
5559 the destinations you allow.
5660
57- Registry servers default to ** Isolate behind an HTTP proxy** unless the registry
58- entry declares a different mode. Custom servers default to ** No isolation** ;
59- switch to the proxy mode to opt in.
61+ Both registry and custom servers default to ** Isolate behind an HTTP proxy** ,
62+ because ToolHive enables network isolation by default. Registry servers pre-load
63+ any allowed destinations declared in their registry entry. To give a server
64+ unrestricted network access, switch to ** No isolation** .
6065
6166### Restricting proxied traffic
6267
@@ -100,6 +105,21 @@ purposes; the form displays a warning in this case.
100105
101106:::
102107
108+ ### Allowing host machine access
109+
110+ When a server runs behind the HTTP proxy, ToolHive blocks connections to Docker
111+ gateway addresses (` host.docker.internal ` , ` gateway.docker.internal ` , and the
112+ Docker bridge gateway IP) by default, even when you allow all destinations.
113+ Reaching the host machine is a separate, more privileged opt-in.
114+
115+ Enable ** Allow host machine access** to let the server connect to these gateway
116+ addresses. Turn this on when your MCP server needs to reach a service running on
117+ your host machine, such as a database or a local development server.
118+
119+ Host machine access is port-independent: once enabled, the gateway is reachable
120+ on any port, regardless of the allowed ports you list. You don't need to add the
121+ gateway hostname to the allowed hosts.
122+
103123## Example configuration
104124
105125With ** Isolate behind an HTTP proxy** and ** Selected destinations** chosen, the
@@ -118,19 +138,19 @@ and all subdomains of `githubusercontent.com` on port 443 (HTTPS):
118138
119139### Accessing other workloads on the same container network
120140
121- To allow an MCP server to access other workloads on the same network, choose
122- ** Isolate behind an HTTP proxy** with ** Selected destinations** , then list the
123- appropriate hostnames and ports. This is commonly needed when your MCP server
124- needs to communicate with databases, APIs, or other services that are running on
125- your local host during development.
141+ MCP servers often need to reach services running elsewhere during development,
142+ such as databases, APIs, or other local servers.
126143
127- For example, in Docker environments, you can add ` host.docker.internal ` to
128- access services on the host. ` host.docker.internal ` is a special hostname
129- provided by Docker that resolves to the host machine's IP address from within
130- containers.
144+ To reach a service on your ** host machine** , enable
145+ [ ** Allow host machine access** ] ( #allowing-host-machine-access ) . The server can
146+ then connect to ` host.docker.internal ` (on macOS and Windows) or the Docker
147+ bridge gateway IP (typically ` 172.17.0.1 ` on Linux) on any port. Because these
148+ gateway addresses are blocked by default, adding them to the allowed hosts list
149+ alone is not enough; you must enable this option.
131150
132- - ** Allowed hosts** : ` host.docker.internal `
133- - ** Allowed ports** : ` 3000 `
151+ To reach a service that is ** not** on the host machine, add its hostname and
152+ port to the allowed hosts and ports under ** Selected destinations** , as
153+ described in [ Restricting proxied traffic] ( #restricting-proxied-traffic ) .
134154
135155## Next steps
136156
@@ -154,9 +174,10 @@ containers.
154174 settings, select the ** Network access** tab, and confirm the mode is
155175 appropriate for the server. If the server is set to ** Isolate behind an HTTP
156176 proxy** with ** Selected destinations** , confirm the hostname and port the
157- server needs are listed. Proxied network isolation only supports HTTP and
158- HTTPS, so direct TCP connections (databases, custom protocols) won't work in
159- this mode.
177+ server needs are listed. If the server needs to reach a service on your host
178+ machine, make sure ** Allow host machine access** is enabled. Proxied network
179+ isolation only supports HTTP and HTTPS, so direct TCP connections (databases,
180+ custom protocols) won't work in this mode.
160181
1611822 . Check the server logs from the ** MCP servers** page. Select the server, open
162183 the logs panel, and look for connection errors or denied requests.
0 commit comments