Recent Posts (Page 18)

Cleaning Up Nameless EC2 Instances with Ansible

I gave a talk at the recent London Ansible Meetup on how I cleared up unexplained nameless/‘anonymous’ EC2 instances from our AWS account at YPlan. This is the blog post version of that talk, so you can follow along and stop such instances appearing on your account and sapping money!

Read more...

Validating Ansible changes

If you’re using ansible to set a configuration file for a program, one of the most important things you can add is a validation step to ensure that you don’t hit reboot and the program refuses to launch - service down!

Read more...

Merging groups and hostvars in Ansible variables

I was googling for information on creating round-robin DNS records in Route53 with Ansible and came across this post by Daniel Hall who’d figured out a way of merging the his host group list with their hostvars in Ansible. After a bit of emailing with him I’ve figured a way to do it without having to add an extra filter as he did originally - by digging more into Jinja2.

Read more...

Using IPython Notebook to Write Jekyll Blog Posts

My last blog post was written in IPython notebook, and my blog is in Jekyll. Here’s how I hooked the two up.

Read more...

Python Concepts: Part None

Let’s learn about nothing. More particularly, let’s learnt about python’s concept of representing nothing, None. This is the most nothingest concept of nothing as well - for example, zero is nothing, but it’s also a number, so it still has some information. Other names for nothing from other programming languages include null, nil, or Nothing.

Read more...

My Talk “Factory Boy Fun” at Django London Meetup

On Tuesday I gave another talk at the London Django Meetup Group, titled “Factory Boy Fun”, based upon my previous blog post of the same name. The blog post covers pretty much the same stuff, but if you want to flick through the slides quickly for an overview, they’re hosted on GitHub.

Read more...

Factory Boy Fun

I’ve recently been working on improving the test suite at YPlan. The biggest change is moving towards dynamic fixtures for our Django models using “Factory Boy”. This library is essentially a tool that lets you define simple helper functions to generate random, sensible model instances quickly; by using them in tests you can avoid the static JSON fixture files that Django recommends you use in tests by default. Factories are also general purpose - they just generate data and use it to create a model - and so they can be re-used to fill your development database rather than dumping from production.

Read more...

Time to Move on From Cron

I was recently tasked with keeping the various repeating jobs running for our data scientists at YPlan. They have a number of nightly or weekly jobs to be run, such as creating summary tables of the day’s various activity logs, pulling in data from third party services, and so on.

Read more...

My Talk “Django at scale” at Django London Meetup

On Tuesday I gave a talk on Django at the London Django Meetup Group, titled “Django at Scale.” The slides are hosted on GitHub.

Read more...

DevOps Exchange London: Continuous Delivery

Last Thursday (24th July 2014) I went to the DevOps Exchange London Meetup on Continuous Delivery; here is my quick review of the talks and what I took away.

Read more...

Five Neat Little Python Libraries

Here are some great little Python libraries that have made my life (well, at least the coding part) a little bit nicer and easier. They mostly add neat syntax and a few things that you always wanted to do, but never knew.

Read more...

Installing and Removing R Packages With Ansible

I was asked by some of our Data Scientists to get a few R packages onto their server, which I configured by Ansible. R seems to be bit funny compared to other programming languages because it’s package installation happens inside R code, rather than with a dedicated commandline utility.

Read more...

Extending Django’s QuerySet to return approximate COUNTs

I was looking through the MySQL slow_log for YPlan and discovered that there were a lot of SELECT COUNT(*) queries going on, which take a long time because they require a full table scan. These were coming from the Django admin, which displays the total count on every page.

Read more...

Some Ansible Hints

Three useful little tidbits for using Ansible that I've come across.

Read more...

What I Learnt Losing a Million Pageviews

Open the page.

Read more...

One Minute Happiness

Open the page.

Read more...

Meet Mary

Open the page.

Read more...

My Encounter with Frozen Dead People

Open the page.

Read more...

The T-Shirt That Makes You More Creative

Open the page.

Read more...