def Tls.open.sent
import bend-kube-runtime@0.2.0.0/src/net.bend as Netimport Base
import bend-kube-runtime@0.2.0.0/src/proxy.bend as P
98def Tls.open.sent(p: Socket & Res(Unit), +host: String, ca: String, cert: String, key: String,
99 +ms: U32) -> IO(Res(Socket)):
100 match p:
101 case (s, Done{u}):
102 Tls.tunnel(4294967295n, TStep{s, P.Tunnel.init()}, host, ca, cert, key, ms)
103 case (s, Fail{(c, m)}):
104 Tls.fail(s, (c, "proxy: " ++ m))