1 hour ago · Tech · hide · 0 comments

I’ve written before about using bunny.net as a CDN for this blog, where I basically just cache everything, because it’s a static blog. Whenever I release a new blog post, I purge the pull zone, and the new blog post becomes available. This works great for my blog, it doesn’t have user sessions, no server side dynamic content, also crucially it doesn’t use LiveView websockets. It basically means serving my blog requires no resources on my side at all, it’s fully CDN driven. For your average Phoenix LiveView web app this won’t work so well though. You’re very likely to have dynamic content, user sessions, and websockets. After some experimentation I found a really high impact low effort approach to using bunny.net for this use case, so here’s a little write up. Note that there are other CDNs out there too and you should be able to use them just fine with this guide! A CDN that doesn’t get in your way Looking over your average Phoenix LiveView web app, the stuff you want to cache is…

No comments yet. Log in to reply on the Fediverse. Comments will appear here.