DoPECC Reboot

The DoPECC site was originally hand-coded in HTML using the Bootstrap CSS framework. This was useful as a means to learn some small amount of HTML, CSS and site design. Over the following five years this became increasingly difficult to maintain, to the point where the site was not being updated much due to the side effects that would be triggered by new material, each effect having to be manually resolved.

I did not want to move the site to one of the common site design or blogging platforms because this would mean locking the site and all its material into that platform and most likely into a series of third-party plugins and addons. The original hand-coded design was done to keep the site independent of platform and I did not want to give this up. Many of the common platforms and plugins have become serious hacking targets and owners of such sites must devote regular time and effort to maintenance and updates.

Static Site Generators finally provided an update path for DoPECC that satisfied the original technical requirements:

  • Full ownership and control of all content
  • Authoring in portable generic Markdown format
  • No structural maintenance, no maintenance of foreign code such as plugins
  • Smallest attack surface

Static Site Generators compile the site’s source into HTML/CSS that is uploaded to a hosting service and served directly, with no other processing. This architecture does limit interactivity and real-time data serving but this is not so relevant for sites such as DoPECC that are primarily informational and actually pretty “static” in terms of content.

Serving static HTML/CSS offers advantages:

  • Fast serving from low-resource hosts
  • Economical hosting using low-resource hosts
  • Minimal attack surface
  • Little or no requirement for structural maintenance

DoPECC Reboot with Hugo, Static Site Generator

Hugo was chosen for the DoPECC reboot. Hugo is among the half-dozen most popular Static Site Generators, others that were considered included:

  • Gatsby and Next: both are based on React/JS which are unfamiliar to me
  • Jekyll: based on Ruby, again unfamiliar

Hugo is based on the Go language, this too was unfamiliar and indeed somewhat arcane. There is definately a significant learning curve but once this is overcome the Hugo environment is smooth,fast, easy and fun to use. The Hugo community is very supportive and forum queries are often answered within minutes!

The small, fast Hugo executable is downloaded and installed on your personal machine. This executable parses your Markdown content, generates a directory tree of HTML and provides a webserver for live editing and review as you write. The development environment is completely self-contained, interactive and can be used offline. When you are happy with a set of updates and how they render, the final HTML directory is generated and the diffs are uploaded to your hosting provider. There are no plugins to maintain, no server code to maintain and the attack surface is minimal. All your time can be spent on site content.

There is a moderate learning curve but the excellent Hugo community is generous with support.

Hugo versions after mid-2018 provide excellent functionality in an easy and interactive content creation environment. For sites such as this, Hugo is warmly recommended.