Im doing exactly this, but will use it with a raspberrypi with a 7 inch touch screen as my doorbell. Someone hits the link on the screen, it hits the server, server texts me a link to join the video session and thats it really. I got the core code going (I used a simple tornado [python] implementation as it has web sockets built in)<p>This is the version of the js code that I got going (I couldn't reason about straight inline scripting, I had to make unnecessary classes. you dont need them) <a href="https://gist.github.com/emehrkay/1ea9a87a91e00b27843d9b71a3cce96c" rel="nofollow">https://gist.github.com/emehrkay/1ea9a87a91e00b27843d9b71a3c...</a><p>You also need to tell nginx to serve the wss connection with http 1.1 or the handshakes fail<p>```
location /websocket/path {
proxy_pass <a href="http://whateverSiteDotCom;" rel="nofollow">http://whateverSiteDotCom;</a>
proxy_http_version 1.1;
proxy_set_header Connection "upgrade";
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Origin '';
}
```
I feel like part of the reason why software engineering projects are hard to estimate is this. So you want to add video chat..<p>- this blogpost: 100 loc
- pion (open source): 100k loc?
- dolby.io/ agora: I'm guessing >1m loc
- zoom.... even more?
Not quite so easy as the blog makes out... didn't see any mention of turn and stun servers, and multi-peer adds layers of complexity...<p>To stably build a negotiation system you'll probably need an infrastructure of websockets and some kind of nosql db to handle identity and other quirks around negotiation...<p>Example... how do you handle refresh from a new tab or after the connection has dropped... some kind of device signature is probably needed too!!<p>(We've just spent a year building this for ecommerce @ <a href="https://yown.it" rel="nofollow">https://yown.it</a>)<p>BIG thumbs up for the interest in WebRTC though enormous potential...
I tried this myself too and when I try p2p with 4 people, out of 10 tests about 50% of the time I won't be able to see all 4 people or someone wouldn't be able to see all 4 people.<p>It was really hard to make p2p work and debugging the ice connections was even harder.
...and GCP, and pub/sub/ and...<p>So a little click baity title. If the backend wasn't distributed the title would be a little more apt.
i wonder if webrtc was built to be intentionally complex or if a better standard would make adoption easier, perhaps in conjunction with a standard server (like we have httpd for html)