Skip to main content

About the Site

I thought it might be useful to give some background about the website for those that are interested.

Under the hood there are two Hetzner Cloud virtual machines running Ubuntu OS, one for the Database and the other for Dashboard elements.

Hetzner’s minimum spec offering at less around 5 Euros/month per server is proving more than adequate for the current traffic and load.

You can claim 20 euros of free Hetzner credit using my referral link if you fancy creating your own online project.

Here’s a breakdown of what runs on each server

Database Server

  • InfluxDB
  • Grafana

Dashboard Server

  • Grafana

I run two separate Grafana instances to keep the main site graphs and the Dashboards away from each other.

WordPress Website Hosting

I used to run my own Hetzner VM to do this, but I migrated everything to in early 2023 as I was fed up trying to keep the underlying operating system, PHP and the suchlike patched and secure.  Moving to a hosting company meant all that was taken care of as well as offering free daily backups, SSL certificates and a staging site to do development on.

34SP are a hosting company based in Manchester and I’ve used them for around a decade for various web projects.  Being in the UK their support is first class and I can’t recommend them highly enough.

You can claim a free months hosting with them if you mention when joining.

API Calls and Code

To pull the data from Octopus each day I schedule a bunch of self built Python scripts to call the Octopus Energy API and insert the data into the Influx database.

There are also other custom scripts that create the daily graphs (using MatplotLib) and tweet out to the @energystatsuk Twitter account and also prepare the updated CSV files for the Download data page.

Luckily for me, the Grafana graphs are static html calls as you can use date ranges like -1d and -7d etc so that the graphs just pull the correct data each time they are run.  Every time a page on the site is visited and a graph populated on screen the data is pulled every time from the database server and displayed on the website.

Jack of all trades, master of none!

Whilst I have worked in IT for almost 30 years making this site was well out of my comfort zone and a journey of adventure.  I’m like a jack of all trades, master of none and I don’t mind admitting that Google and Stack Overflow went a long way towards the building of the site.  Just goes to prove you can teach an old dog new tricks.

Any questions about the site, any suggestions about future blog topics or comments about any of my other existing blog entries, please let me know via the contact form.

Close Menu