public void Receive(HostSettings settings) { var port = settings.Port; Relay (settings); Link ("http://localhost:{0}".Fmt (settings.Port)); }
public void Relay(HostSettings settings) { var port = settings.Port; var host = new NancyHost (new Uri ("http://localhost:{0}".Fmt (port)), new WarpgateBootstrapper (kernel)); host.Start (); var relayServer = new RelayServer (); relayServer.Start (); kernel.Bind<IRelayServer> ().ToConstant (relayServer); }