single socket ice (#232)

Enables single socket for HOST and SRFLX candidates by utilizing pion.ice UDPMux
This commit is contained in:
Mikhail Bragin
2022-02-16 20:00:21 +01:00
committed by GitHub
parent 765d3a0ad0
commit e5dcd4753e
5 changed files with 107 additions and 40 deletions

View File

@ -256,6 +256,7 @@ func TestEngine_Sync(t *testing.T) {
select {
case <-timeout:
t.Fatalf("timeout while waiting for test to finish")
return
default:
}
@ -397,11 +398,12 @@ func createEngine(ctx context.Context, cancel context.CancelFunc, setupKey strin
ifaceName = fmt.Sprintf("wt%d", i)
}
wgPort := 33100 + i
conf := &EngineConfig{
WgIfaceName: ifaceName,
WgAddr: resp.PeerConfig.Address,
WgPrivateKey: key,
WgPort: 33100 + i,
WgPort: wgPort,
}
return NewEngine(signalClient, mgmtClient, conf, cancel, ctx), nil