Off-Cloud Backup for Heroku apps – a possible answer

The Heroku platform is an absolutely fantastic way to have to not bother with devops within a small development company. We’ve been using it at interconnect for years now, and whilst it’s not entirely perfect, it takes away one set of headaches and does so at a reasonable cost.

All the services offer backups, and the VMs are built from scripts and are essentially read only. So if something catastrophic happened to one of our databases, we can roll back a day and be OK. Except… let me explain my fears around data.

Trust issues with providers

In our very earliest years we used a VPS provider that used Plesk. Everything was solid and stable until one day, we got a report that a site had been hacked. Then another. It turned out that a vulnerability had exposed our sites to being hacked. And they were. This resulted in a big old clean up operation and restoration from backups. Except the daily backups we’d been paying for turned out to be weekly. So the backups we had were three days old. Ever since then, I’ve preferred to have a way of pulling backups separately to a server under my own control, unless the provider is Kumina, because I know the people so well that I’m 100% certain they’re as paranoid as I am and they’ve never ever let me down. But in the era of hustle culture bros who move fast and break things, you need a safety net.

Creeping corruption

My next fear is corruption you don’t notice immediately. I can well imagine that if all the meta data for the posts on a site before a certain date got wiped out, most people wouldn’t notice for ages. Imagine you’ve got a site with 200,000 posts, and various elements of the first 100,00 were damaged – the long tail matters to these sites and suddenly it’s all gone. Well, thank heavens for backups!

Except, of course, most cloud providers don’t provider substantial generational backups. Instead, they keep a few days or a week or so. And that’s your lot. If you need to go back months you’d better hope a developer in the company left a dump on their laptop somewhere – except of course that very very few developers keep dumps of production systems on their laptops – it’s bad practice and only tends to happen in exceptional circumstances and should be deleted soon after use.

How we fix it today

In the end, I asked one of my Linux oriented colleagues, Gianluigi, to create a service that would connect to Heroku’s API and then download every database, and sync every S3 bucket. It worked, with some limitations. More recently, because he’d left but remains a good friend, he helped me with a crash course in Linux sysadmin basics and I was able to extend and improve some bits. The system is a service written in PHP that does all the work. I then asked another colleague internally, Jack, to extend things to cover the PostgreSQL databases we also now used and to create a dashboard so that I could monitor the backups easily without resorting to logging into the backups servers.

The dashboard also doesn’t run on the backups servers. I needed to keep the backups as safe as possible – they’d be a great honeypot for a hacker, so they’re onioned away, and the backups service isn’t reachable from outside. Instead, it messages the dashboard with information about the backups taken. The dashboard also provides details on application and framework versions, for security monitoring and making sure updates have been applied appropriately, and it also sends me a daily summary email showing me storage space available and what was backed up in the previous 24 hours.

Here are a few screenshots of the system, with some censoring, but I hope you catch how it works from what you see.

To commercialise, or not?

And now to one of the reasons why I’ve decided to write about this. In the past, I created the first version of Search Replace DB – a quick script and algorithm I knocked up to parse a database and search and replace items in it. A fast, dangerous tool that I released as free open source code. Other people took it and commercialised it into successful products. We didn’t. And with the code being integrated into wp-cli and most devs would use that in preference (myself included!), except in those tricky situations where command line access wasn’t possible – mostly on cheap hosts. I think we were right to release the code, but where we failed was in realising the commercial possibilities. And that’s left me a little torn.

So now I’m torn – it’s not easy to set up services in Linux, but once you do, these things just run and run. It’s also not going to be the easiest thing to work with, so I anticipate support costs being quite high. It’s proper server level work. And I certainly don’t feel inclined to build a SaaS that acts as a conduit for people’s backups. It’s just too risky to have a central pool of lots and lots of backups, and people find them lurking on S3 buckets all the time. So I want to put this out to the community. Is this something you’d find useful? Let us know in the comments below. If we did release it, the code would be open source, but access to the latest versions would be restricted.

I’m looking forward to hearing your thoughts!

Liverpool Central Library

So, Liverpool Central Library has had a revamp.

The reading room was always ace, but had been closed for ages and I’d not been able to show it to friends. It’s now all been lovingly restored, and the ‘modern’ bit done in a much more interesting manner with wonderful natural light.

It’s great to see Liverpool getting these projects – the city gets nicer and nicer to work in.

Bell & Coggins Pattern 1321

I have a little selection of Bell & Coggins Porcelain that I inherited but which isn’t really something I’m ever going to make much use of – it doesn’t really fit with anything else we have and it’s too delicate to have around when you have young children.

So, better that somebody who would enjoy it should have a chance to own it!

Head over to eBay if you’re interested.

Here’s the set:

Bye Bye Skoda

It’s always sad when you decide to get rid of a car that you’ve enjoyed owning.  Not because it’s no good, but because your needs have changed.  And the biggest problem was that we’re now parents to one growing toddler and another relatively new baby.

Which nearly did my back in.  Both the Skoda and the Audi are relatively low cars, and as I have a weak back as it is, this proved too much and I recently found myself barely able to move for a weekend.  Not good.  I decided it was time to find a taller car.

So, with a heavy heart, I’m selling my 77,000 mile late 2004 Skoda Octavia vRS.  As you might expect from me, it’s been well looked after, has a full service history and no expense has been spared in its maintenance.  It’s a cracking car with great performance, handling and pretty good refinement.

I’ll let the pictures do the rest of the talking.  If you’re interested, drop me a line in the comments below.  I’ll be adding a contact number on here shortly once the Telesafe number’s come through.

Price? Just £3100 – a lot of car for little money.  I’ll be sad to see it go.

Do You Need an SLR?

OK, I’ve always said that you don’t need a fancy camera to take good pictures.  All that a good camera does is add flexibility and choice, but so long as there’s a decent amount of light (and even then, not necessarily that much) a compact or a smartphone camera could well be adequate.

This lunchtime I went for a walk but was dismayed to find my trusty Lumix LX3 wasn’t in my backpack.  I decided I should still try and take pictures, however.  The light was flat, the weather uninspiring, but let’s try with the smartphone camera and see what comes up.

I’m going to have a go at doing this as a regular feature.  Just to challenge my abilities with composition and creativity.

I will admit to one thing, however – I’ve post-processed.  I usually post pictures up as they came out of the camera, but sometimes you need to tweak at least a little – and smartphone cameras are pretty limited in their controls for contrast and colour.

Thinking Digital University (2011)

So, here I am again at Thinking Digital.  Only this time I’m no longer driving the seemingly doomed Golf TDI I had last year that did one of it’s self destruction tricks en-route.  Consequently I’m not missing out on the workshops here.

In fact, I’m doing better than that – an additional workshop was added for the Monday by Jer Thorp of Wired fame.  A workshop on Processing.  That, I must say, was a wonderful find.  Processing, in case you’ve never heard of it, is a data visualisation tool or sketchbook.  It’s a bit old-school, but this is a good thing, generally, because this has the advantage of being relatively accessible.  In fact it reminded me of the fun early days of BASIC on small computers.

Simply put, you can easily draw things, and you can analyse data with it.  Some was stuff I could do on a Dragon 32 nearly thirty years ago, but with many thousands of times the power – and that means you can do cool stuff in real time.  I recommend you look up some of the online Processing materials.  You can even try it out without installing anything by using my colleague Robert O’Rourke‘s website, hascanvas.com

During Nancy Duarte’s Workshop

That Resonates With Me!

Then on day two it was a half day ‘off’ which, for me, meant a series of telephone calls with clients while I ensure that work continues as it should.  The afternoon, however, brought along Nancy Duarte‘s “That Resonates With Me!” workshop.

Funnily enough, her resonate analogy was the one bit that didn’t work for me.  She used the peculiar patterns of salt as it’s vibrated on a plate as a way of showing how different people can resonate with your message in different ways.  It’s interesting, but I feel that people don’t work that way.  People can, however, be like salt – you know, small, hard, square and bad for your health.  So perhaps she had a point.

BUT – I’m picking.  Because truth be told it was a fascinating workshop that helped me to see through the clutter of my presentations and to find ways to understand my audience and find ways to connect with them.  The simple exercise she gave will help me improve my presentations – of that I’m sure.  I just have to make sure I put them into practice.

The Rest

The rest of the conference is more classically organised, with the usual talks, networking and information overload.  In the evenings there’ll be the usual entertainment.  Already I’ve been better at avoiding alcohol than last year – I’m remarkably sober tonight.  This is a Good Thing.

Highlights, I suspect, will be Jer’s talk (always visually amazing – check out his Vimeo feed) but the rest I’ll have to report on later.

Peru, Chile & Bolivia Gallery

A gallery of some of my favourite in-camera images from Peru, Chile and Bolivia a few weeks ago.  They’re not necessarily strong photos or selected as such – just photos I myself enjoy.  I have more, but they either need tweaking (straightening horizons, etc) or some real work to bring out the best.  I’ll post them up soon enough.  No particular order.

Enjoy:

Dogs of San Pedro

I had an afternoon to kill, prior to heading back towards Arica.  So what’s a boy to do?  Well in my case I wondered around the village taking pictures of anything that caught my fancy.  But one possible theme leapt out at me – the many dogs around the streets would make a lovely topic to follow.

So here, I present, the dogs of San Pedro de Atacama.