I was trying to expose my OctoPrint server through Cloudflare using cloudflared, which works similar to ngrok but offers quite a bit of additional functionality. I use it for several other apps I host off my home network and figured it would be pretty simple, but for some reason the WebSocket connection seems to fail without much useful information (likely by something in cloudflare). I've read through the Cloudflare documentation on WebSockets and tried tweaking a few
WebSocket connection to 'wss://octopi.example.com/sockjs/039/3myxvhxc/websocket' failed: packed_libs.js?1fe9f29c:1238
I don't see any errors in the octoprint.log.
Anyone have any thoughts of what could be causing this failure?
I guess there might be something incompatible with Cloudflared. It is very hard to work out what is going on there. Does cloudflared have any of it's own logs? Is that error message in the browser console? It seems like after failed: it should have some kind of reason - or at least, that would make it useful
You do get a warning in Octoprint that you should be careful exposing your printer to the internet. I think I'm comfortable since I have a strong password, it's HTTPS, and I have some security features enabled in Cloudflare. Though I ought to have some 2FA enabled somehow.
I was able to get a tunnel working with a basic install, and able to control the system with Octoremote. I made a post earlier today about it. The only issue I have is not being able to view the webcam. Were you able to get the webcam viewable through the tunnel?