I have a project, hosted on Ubuntu 20.04 server, then I zipped it along with node_modules to move the host to CentOS 7 since there is no internet available on it.
The code on Ubuntu 20.04 is working normal, but not working on CentOS 7.
The problem is when I passed iceServers to new PeerConnection(), the peerConnection is closed immediately.
const pc = new RTCPeerConnection({
iceServers: [{
urls: "turn:some.existing.turnserver:4444",
username: "someusernamehere",
credential: "somecredentialhere"
}],
sdpSemantics: "unified-plan",
});
console.log(pc.iceConnectionState);
The result of console.log above is "closed"
Also, my turn server log doesn't show that there is any connection attempt. So the nodejs is not reaching the turn server at all.
const pc = new RTCPeerConnection({
iceServers: [],
sdpSemantics: "unified-plan",
});
console.log(pc.iceConnectionState);
The result of console.log above is "new"
What I tried:
tested the turn server using ICE Trickle: turn server is working
change the passed iceServer to some non-existing ip: the same exact result as when I passed the right ip.
check the firewall: Firewall is OK. I can ping and telnet to Turn server.
My question is:
Since the node_modules are installed on Ubuntu, should I reinstall the node_modules on CentOS?
Thank you.
--- UPDATE ---
I already reinstall node_modules using my local CentOS WSL and upload the node_modules, but the result is still same.
Environment: OS: CentOS 7 TURN server: Coturn 4.5.1.1 NodeJS: 14.16 node-webrtc: 0.4.7
I have a project, hosted on Ubuntu 20.04 server, then I zipped it along with node_modules to move the host to CentOS 7 since there is no internet available on it. The code on Ubuntu 20.04 is working normal, but not working on CentOS 7.
The problem is when I passed iceServers to new PeerConnection(), the peerConnection is closed immediately.
The result of console.log above is "closed" Also, my turn server log doesn't show that there is any connection attempt. So the nodejs is not reaching the turn server at all.
The result of console.log above is "new"
What I tried:
My question is:
Thank you.
--- UPDATE --- I already reinstall node_modules using my local CentOS WSL and upload the node_modules, but the result is still same.