Surge CDN for Deployment

Surge.sh is for static files. If you’re building a web app with a static files build, either perfectly autonomous or getting data from a webservice, it’s a viable hosting solution. It’s not for PHP (or any other server-side process), hence not for Kirby.

If you want to go fully static, you could have:

  • a staging server with a Kirby instance and access to the Kirby panel etc. (hosted on something as limited as shared hosting, one one side)
  • a PHP script that outputs static HTML files for every page of this Kirby website, and perhaps copies over the necessary static content (images, audio and video, pdf, etc.) on the staging server as well
  • a deploy script that puts all the generated and copied over static content to Surge.sh, or any host for that matter

Bastian recently talked about a big project using that kind of setup (a more complex one actually).