From ef330e1bbca5ab859f033fc1a104397540a13e64 Mon Sep 17 00:00:00 2001 From: Tomer Date: Sat, 24 Jul 2021 12:29:43 -0400 Subject: [PATCH] feat: Import a separate file for ICE servers --- www/iceServers.js | 18 ++++++++++++++++++ www/index.html | 1 + www/script.js | 19 ------------------- 3 files changed, 19 insertions(+), 19 deletions(-) create mode 100644 www/iceServers.js diff --git a/www/iceServers.js b/www/iceServers.js new file mode 100644 index 0000000..74f66a9 --- /dev/null +++ b/www/iceServers.js @@ -0,0 +1,18 @@ +const ICE_SERVERS = [ + { urls: "stun:stun.l.google.com:19302" }, + { urls: "stun:stun.stunprotocol.org:3478" }, + { urls: "stun:stun.sipnet.net:3478" }, + { urls: "stun:stun.ideasip.com:3478" }, + { urls: "stun:stun.iptel.org:3478" }, + { urls: "turn:numb.viagenie.ca", username: "imvasanthv@gmail.com", credential: "d0ntuseme" }, + { + urls: [ + "turn:173.194.72.127:19305?transport=udp", + "turn:[2404:6800:4008:C01::7F]:19305?transport=udp", + "turn:173.194.72.127:443?transport=tcp", + "turn:[2404:6800:4008:C01::7F]:443?transport=tcp", + ], + username: "CKjCuLwFEgahxNRjuTAYzc/s6OMT", + credential: "u1SQDR/SQsPQIxXNWQT7czc/G4c=", + }, +]; \ No newline at end of file diff --git a/www/index.html b/www/index.html index df9c187..c5c557d 100755 --- a/www/index.html +++ b/www/index.html @@ -28,6 +28,7 @@ + Talk - Free group video call for the web diff --git a/www/script.js b/www/script.js index 64cecef..7741610 100755 --- a/www/script.js +++ b/www/script.js @@ -1,23 +1,4 @@ /* globals App, io, cabin*/ -const ICE_SERVERS = [ - { urls: "stun:stun.l.google.com:19302" }, - { urls: "stun:stun.stunprotocol.org:3478" }, - { urls: "stun:stun.sipnet.net:3478" }, - { urls: "stun:stun.ideasip.com:3478" }, - { urls: "stun:stun.iptel.org:3478" }, - { urls: "turn:numb.viagenie.ca", username: "imvasanthv@gmail.com", credential: "d0ntuseme" }, - { - urls: [ - "turn:173.194.72.127:19305?transport=udp", - "turn:[2404:6800:4008:C01::7F]:19305?transport=udp", - "turn:173.194.72.127:443?transport=tcp", - "turn:[2404:6800:4008:C01::7F]:443?transport=tcp", - ], - username: "CKjCuLwFEgahxNRjuTAYzc/s6OMT", - credential: "u1SQDR/SQsPQIxXNWQT7czc/G4c=", - }, -]; - const APP_URL = (() => { const protocol = "http" + (location.hostname == "localhost" ? "" : "s") + "://"; return protocol + location.hostname + (location.hostname == "localhost" ? ":3000" : "");