This website

Before I move on with writing more of what I planned, I need to write a few things down about how this website came to be.

A long time ago I used GitHub Actions for my blog. I didn't quite like because of how slow the feedback loop was: I had to wait sometimes 30+ seconds in order to see an update I pushed show up on a live website. 30 seconds is... well, it's too just slow for my taste. I decided my next website will on a hardware I own or, at the very least - rent :)

Today this website runs on:

I am using goaccess to visualize HTTP access logs. I don't need anything sophisticated yet, so today I check the logs via this simple script:

show-access-logs.fish
#!/usr/bin/env fish
set access_log (mktemp)
echo $access_log
scp 128.135.95.176:/var/log/caddy/access.log $access_log
goaccess $access_log --log-format caddy

I might need to run goaccess as a NixOS service one day.

Fun fact: a little over 24h after configuring access logs in Caddy, the website was visited 6841 times from 115 unique visitors. Bots, of course. Someone wrote about this recently.

Might need to look into integrating fail2ban, anubis or the like into Caddy.


Finally, deploying this website is as simple as running the following two commands:

env MIX_ENV=prod mix tableau.build
rsync --archive --verbose --delete /Users/eugene/projects/website/output/ 128.135.95.176:/var/lib/www/ievgenpyrogov.com/

This way I can store the website's sources in a folder on my laptop, and make an update live in just a couple of seconds. This is a welcome improvement over "deploying" website using a GitHub Actions workflow and enables me want to make many small updates frequently.