Minimizing the blog hosting costs

I have hosted this blog in Azure App Service (B1 Tier) for a few years now. This App Service has been worked in my Azure Subscription (Visual Studio subscription). Visual Studio subscription provides monthly Azure credits which can be utilized for testing Azure services. Visual Studio Enterprise provides Azure credits for ~150€/month. This week I noticed that I forgot Azure API for FHIR up and running in my Azure Subscription which consumed all credits. After that, my blog obviously stopped working and I had to invent something.

If you're interested in the technical details of this blog check this post.

What did I do?

In simplicity, the plan was to change the App Service Plan to Free Tier, crawl the static content of the Blog, and upload it to GitHub Pages.

1. App Service Plan change

The highest costs were produced by the App Service (B1) so I created a new App Service Plan with Free Tier. Free Tier enables compute time for 60 min/day which is enough especially when this App Service application is no longer the façade of the Blog. In this new model access to App Service will be also restricted.

2. Crawling the static content

I used an application called HTTrack to crawl the App Service (Free Tier) based site and copy static content (HTML, CSS, Images, etc.) to my local computer disk.

3. Publish content to the new hosting platform

GitHub Pages provides a free platform to host static files so this is an ideal home for my Blog. The solution is good because you can also use a custom domain with GitHub Pages. 

What Next?

The current solution requires some manual work to publish content to a new platform. Later I'll investigate how to automatize the publishing process using Azure tools.

Comments