Send stun servers to clients (#69)

* Send stun servers to clients

* use TURN/UDP as STUN servers
This commit is contained in:
David Zhao
2021-07-26 15:43:26 -07:00
committed by GitHub
parent d49d541a9e
commit f8782fae3f
2 changed files with 28 additions and 11 deletions
+8 -6
View File
@@ -12,6 +12,11 @@ import (
"gopkg.in/yaml.v3"
)
var DEFAULT_STUN_SERVERS = []string{
"stun.l.google.com:19302",
"stun1.l.google.com:19302",
}
type Config struct {
Port uint32 `yaml:"port"`
PrometheusPort uint32 `yaml:"prometheus_port"`
@@ -104,12 +109,9 @@ func NewConfig(confString string, c *cli.Context) (*Config, error) {
UDPPort: 0,
ICEPortRangeStart: 0,
ICEPortRangeEnd: 0,
StunServers: []string{
"stun.l.google.com:19302",
"stun1.l.google.com:19302",
},
MaxBitrate: 3 * 1024 * 1024, // 3 mbps
PacketBufferSize: 500,
StunServers: []string{},
MaxBitrate: 3 * 1024 * 1024, // 3 mbps
PacketBufferSize: 500,
PLIThrottle: PLIThrottleConfig{
LowQuality: 500 * time.Millisecond,
MidQuality: time.Second,