Eric Polerecky bio photo

Director, Professional Services @RightBrain_Net - 50% engineer, 50% entrepreneur. Former: CTO @Wantify, @agilesoftware, @grasshopper

Eric Polerecky

Email Twitter LinkedIn Github Stackoverflow

Certifications

Xamarin (expired)

Speaking

Microservices? Real World FRP Xamarin Forms Case Study

All Posts

All Posts

After years of using wordpress; I switched to using GitHub’s “ghpages” to host and publish my content. ghpages had many upsides, learning a new technology (Jekyll), hosting for free, speed, writing posts in markdown, and more.

As of today, I’m still using Jekyll but I am moving from ghpages to a linux server on Azure. Here is why I am moving and what my setup looks like.

Jekyll

Jekyll has become my de facto platform when building static sites or blogs. I’m going to stick with Jekyll for the time being…unless the setup I have for hosting/writing becomes cumbersome.

Azure Linux server

Here is where things get interesting. At first I deployed the pre-build static site to Azure App Services and everything worked well after a few config tweaks but I ran into one major problem. I want to run a jekyll build each day so that future dated posts are added to my blog.

Here is what I wanted:

  • onnect App Service to Github
  • Write custom build.cmd / .deployment to install ruby, restore gems and build site
  • Deploy site
  • Schedule daily deployments (so that we run ‘jekyll build’ and pick up new posts)

Everything worked with the exception of scheduling deployments. I got the deployment url from the portal

https://$site:password@detroitpro.scm.azurewebsites.net/deploy?scmType=GitHub

But ran into an error when posting to that URL. So I read the documents on github, https://github.com/projectkudu/kudu/wiki/Continuous-deployment, but still got an error. So I grabbed the webhook url from GitHub, put it into postman but still got an error.

Bottomline; I could not get scheduled deployments to run.

My options are to use VSTS or to stand up a Jenkins server…..well…or just use cron.

I decided to use an ubuntu linux server, install ruby and Jekyll (requires node and gcc) I started writing a build script. The plan was to run it from cron but ended up using Jenkins because I was running into issues with cron (permissions).

Testing

Now that Jenkins is configured and this post is created - with a date in the future - this post should be published tomorrow. I’m going to configure IFTTT to check the RSS feed and tweet the new post.