<story><title>Building video chat into my personal website using WebRTC, WebSockets, and Go</title><url>https://mattbutterfield.com/blog/2021-05-02-adding-video-chat</url></story><parent_chain></parent_chain><comment><author>emehrkay</author><text>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)&lt;p&gt;This is the version of the js code that I got going (I couldn&amp;#x27;t reason about straight inline scripting, I had to make unnecessary classes. you dont need them) &lt;a href=&quot;https:&amp;#x2F;&amp;#x2F;gist.github.com&amp;#x2F;emehrkay&amp;#x2F;1ea9a87a91e00b27843d9b71a3cce96c&quot; rel=&quot;nofollow&quot;&gt;https:&amp;#x2F;&amp;#x2F;gist.github.com&amp;#x2F;emehrkay&amp;#x2F;1ea9a87a91e00b27843d9b71a3c...&lt;/a&gt;&lt;p&gt;You also need to tell nginx to serve the wss connection with http 1.1 or the handshakes fail&lt;p&gt;```
       location &amp;#x2F;websocket&amp;#x2F;path {
                proxy_pass &lt;a href=&quot;http:&amp;#x2F;&amp;#x2F;whateverSiteDotCom;&quot; rel=&quot;nofollow&quot;&gt;http:&amp;#x2F;&amp;#x2F;whateverSiteDotCom;&lt;/a&gt;
                proxy_http_version 1.1;
                proxy_set_header Connection &amp;quot;upgrade&amp;quot;;
                proxy_set_header Upgrade $http_upgrade;
                proxy_set_header Origin &amp;#x27;&amp;#x27;;
        }
```</text></comment>
<story><title>Building video chat into my personal website using WebRTC, WebSockets, and Go</title><url>https://mattbutterfield.com/blog/2021-05-02-adding-video-chat</url></story><parent_chain></parent_chain><comment><author>ejb503</author><text>Not quite so easy as the blog makes out... didn&amp;#x27;t see any mention of turn and stun servers, and multi-peer adds layers of complexity...&lt;p&gt;To stably build a negotiation system you&amp;#x27;ll probably need an infrastructure of websockets and some kind of nosql db to handle identity and other quirks around negotiation...&lt;p&gt;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!!&lt;p&gt;(We&amp;#x27;ve just spent a year building this for ecommerce @ &lt;a href=&quot;https:&amp;#x2F;&amp;#x2F;yown.it&quot; rel=&quot;nofollow&quot;&gt;https:&amp;#x2F;&amp;#x2F;yown.it&lt;/a&gt;)&lt;p&gt;BIG thumbs up for the interest in WebRTC though enormous potential...</text></comment>