Tags: reloaded

Statocles is the foundation of the new website.


This is a setup from the very beginning. It may serve as a cooking recipe while the examples show how I installed this blog.

Install a local Perl

This is not really necessary. It's for those who claim they cannot install some Perl software, because their system Perl is too old, because they are not root or because of any other problem-fu.

You will need perlbrew. If you don't have it already go to the perlbrew website and follow the install instructions.

Now build your local Perl:

me@local:~> perlbrew install perl-5.20.3 --as perl-5.20.3-nothreads
me@local:~> perlbrew switch perl-5.20.3-nothreads

Install cpanminus

me@local:~> curl -L | perl - App::cpanminus

Install Statocles

me@local:~> cpanm Statocles

Create a Git repository for

Basically one needs to create a central repository on the server where the website is hosted.

me@local:~> ssh git@remote
git@remote:~> git init --bare repositories/

I use Gitolite to manage my Git repositories.

me@local:~> cd gitolite-admin
me@local:~> git pull
me@local:~> vim conf/gitolite.conf
... add repo ...
me@local:~> git commit -a -m 'Add repo'
me@local:~> git push
me@local:~> cd

Create a post-receive hook for the remote repository

me@local:~> ssh git@remote
git@remote:~> cat <<EOF >repositories/
umask 002
GIT_WORK_TREE=/srv/www/vhosts/ git checkout -f
git@remote:~> chmod +x repositories/


Get a clone of the website repository and start the Statocles project:

me@local:~> git clone
me@local:~> statocles create
... walk through the setup dialogue ...

At this point let's see if everything is set up nicely.

First check the default setup:

me@local:~> cd
me@local:~> git status
me@local:~> less .gitignore
me@local:~> less site.yml
me@local:~> less blog/2015/09/22/first-post/index.markdown
me@local:~> statocles daemon

Finally deploy the default site and check the result:

me@local:~> statocles deploy
me@local:~> ssh git@remote
git@remote:~> ls /srv/www/vhosts/
blog  index.html  page  robots.txt  sitemap.xml  site.yml  theme

Now configure your preferred web server to serve the generated content.

Piece of cake!