MCPcopy Create free account
hub / github.com/dtormoen/tsk-tsk / connect_proxy_to_network

Method connect_proxy_to_network

src/docker/proxy_manager.rs:753–762  ·  view source on GitHub ↗

Connects the specified proxy container to an agent's isolated network. This must be called BEFORE starting the agent container so the agent can reach the proxy.

(
        &self,
        proxy_container_name: &str,
        network_name: &str,
    )

Source from the content-addressed store, hash-verified

751 /// This must be called BEFORE starting the agent container so the agent
752 /// can reach the proxy.
753 pub(crate) async fn connect_proxy_to_network(
754 &self,
755 proxy_container_name: &str,
756 network_name: &str,
757 ) -> Result<()> {
758 self.docker_client
759 .connect_container_to_network(proxy_container_name, network_name)
760 .await
761 .map_err(|e| anyhow::anyhow!("Failed to connect proxy to network: {e}"))
762 }
763
764 /// Cleans up an agent's network after task completion.
765 ///

Callers 2

acquire_proxyMethod · 0.80

Calls 1

Tested by 1