MCPcopy Index your code
hub / github.com/garrytan/gstack / toUpstreamConfig

Function toUpstreamConfig

browse/src/proxy-config.ts:118–125  ·  view source on GitHub ↗
(cfg: ParsedProxyConfig)

Source from the content-addressed store, hash-verified

116
117/** Convert a ParsedProxyConfig to the UpstreamConfig shape socks-bridge wants. */
118export function toUpstreamConfig(cfg: ParsedProxyConfig): UpstreamConfig {
119 return {
120 host: cfg.host,
121 port: cfg.port,
122 ...(cfg.userId ? { userId: cfg.userId } : {}),
123 ...(cfg.password ? { password: cfg.password } : {}),
124 };
125}
126
127/**
128 * Compute a stable hash of (proxyUrl + headed flag) for daemon-mismatch

Callers 1

startFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected