Actions: | Security

Navigation: Home | Services | Tools | Articles | Other

Building and Deploying this website

This is mostly a simple blogging application. Another you ask? Well, I wanted to have something that provides easy workflow for me.

I'm a sysadmin, not a web developer so my requirements display that bias. I also appreciate lightweight, simple, text-oriented tools.



  • content must be separated from code
  • content and code both live in version control, git.
  • anything that is duplicated should be generated
  • content source should be one of the simple lightweight markup formats such as ReStructuredText, Markdown, etc.
  • simple enough for me to understand once I haven't looked at it in quite some time.
  • the difference between production and development environments is one line in a config file and one change to the calling comand.

The result is a little webapp of a few hundred lines of perl I wrote using the Dancer framework which pulls from an SQLite database using DBIx::Class.

Content is written in ReStructuredText and converted to HTML fragments using docutils. Templates (using Template Toolkit) bring the fragments into the whole which is styled consistently with a single CSS file.



I want:

  • to be able to deploy with a single command
  • a lightweight solution
  • to be able to run on multiple OS/distributions with no changes

A makefile target 'deploy', will check out the latest version of the code, checkout the latest version of the article sources, run the transformation of the article sources and insert them into the database.

Another makefile target 'test', will run tests to ensure that the site is served correctly.

This website is served by nginx, mostly proxying for Starman, which is a PSGI server.