Technical Musings
I write about programming in Ruby. Other articles may contain traces of server infrastructure hacks on Linux/FreeBSD or some light security stuff.
Occasional tinkering produced some Howtos but there a host of other random things dating back to 2009.
Recent Articles
All articles are licensed under a CC-BY-SA 3.0 license unless stated otherwise.
-
2023-05-08 Don't call it *_id!
When storing data consumed from an external service, we often make assumptions on semantics (and types) of data we don't own. Especially other people's unique identifiers.
-
2023-03-24 Constant Doubts
Ruby's public constants often expose implementation details of the defining scope. This articles explores a simple alternative option: singleton methods. Singleton methods everywhere.
-
2022-04-05 What's the point? Or: The 3 Es.
Musings on the arbitrary number we attach to tasks & stories in Scrum teams: dimensions to focus on, the hallowed Business Value, Velocity & Capacity.
-
2019-08-08 Lightweight Technical Designs
Major software development projects merit Technical Design Reviews. Following the same process for all above-average-in-scope projects sounds good in theory but the overhead can be intimidating. “RFCs” offer a lightweight alternative.
-
2019-01-26 Concurrent CSV exports with Ruby IO pipes
To borrow from Zawinski’s Law: Every web application expands to export CSV data (others will be replaced by ones which do).
-
2018-07-30 Build and deploy tinydns data files with Docker
My DNS needs are self-hosted using the djbdns package. This article describes a long-overdue improvement in my DNS deployment. It was also an excuse to play with Docker a little.
-
2017-07-03 Authoring a Private Gem with Gemfury
RubyGems are a great way to share code, but not all code is for the general public. This article illustrates a (semi-automatic) way and some workflow self-discipline to streamline private Gem authoring using the Gem hosting solution »Gemfury«.
-
2017-02-09 Converting a Latin1 encoded HTML Document with Elixir
Content encoding isn't exactly the first thing that comes to mind when you ask developers about a fun task. Our first article covering an Elixir topic illustrates how to make an educated guess about an HTML document's non-unicode encoding and how to convert it.
-
2016-07-21 Dynamically proxy images via HTTPS using Camo
Loading insecure images from within an HTTPS page causes mixed-content warnings. camo is a secure image proxy that lets you get around that. This article explains how to tie camo into your Redcarpet and html-pipeline markdown parsing to rewrite your img tags.
-
2016-05-20 Migrating a legacy gem to use Ruby Refinements
An old gem that's been lying around untouched since 2010 got some refactoring love. Moving away from brutally monkey patching a core class, I used this case as an academic example to illustrate how to test refinements using Test::Unit, MiniTest::Spec and RSpec.
-
2016-05-09 Migrating a qmail-ldap mail server (1)
I'm about to move my qmail-ldap mail service to another host. This article deals with one prerequisite: adding a secondary MX server. Even if you don't use qmail-ldap, you may find this howto helpful for setting up a backup mail toaster. May contain traces of FreeBSD.
-
2016-03-11 Including a Module. With Parameters!
The Ruby include statement only allows for one type of argument: the module constant(s) to include. I've found myself in a situation where I wished I could make the include statement more dynamic, like passing extra arguments that influence the module to be included. This article describes how to use a module factory to achieve exactly that.
-
2015-11-23 Creating an Adhoc File-Backed ZFS-Volume
Temporarily in need of a few hundred gigabytes on a FreeBSD system, I stitched together free disk space on different hard disks via ZFS. The plot twist: I used ZFS on top of two existing filesystems. Also, I think I'm in love with ZFS now.
-
2015-04-19 Freifunk Berlin (kathleen v0.1.x) mit WLAN WAN-Uplink
Ein Erfahrungsbericht meiner Installation eines Freifunkrouters für berlin.freifunk.net, bei dem der WAN-Uplink in Ermangelung einer Ethernetverbindung über einen zusätzlich per USB angestöpselten WLAN-Adapter erfolgt.
-
2015-03-27 Why my Email Inbox is the only Productivity Suite I ever need
I am not afraid of email. Using my email client Mutt, I have long since taken to a special way of dealing with large amounts of email: viewing email threads as trees, brutally changing subject lines and tearing unrelated email bodies apart. Mutt is my Todo-App.
-
2015-02-10 Securely synchronize your KeepassX Passwords
KeepassX is a cross-platform password manager. Password managers are great, but synchronising the password database between multiple devices can be challenging if you want to avoid uploading it to The Cloud. Here is a »secure-enough« way to do it.
-
2015-01-24 Preventing my old PostgreSQL to start after upgrade
Upgrading PostgreSQL with Homebrew left me with the system-wide PostgreSQL installation still starting at system boot.
-
2014-03-13 Debian Wheezy on an iMac
Despising OS X on Apple hardware is a sacrileg to some. For me, having a FOSS operating system on my desktop machine is an important first step to go Apple-less at some point. This article is both a documentation of my experiences and a Howto.
-
2014-02-13 Arbitrary Password Restrictions: Why, Internet, Why?!
While the days of passwords stored in clear-text are long gone (or are they…?), another menace has taken the stage: Password formats! And this is not about those that serve the users' interests… Also, no password is safe!
-
2013-10-10 Rails 4.1: ActiveRecord::Base.find_each Enumerator
Iterators allow for lazy enumeration over a collection of objects. When trying to refactor a simple rate limiter using Ruby blocks, I had to realize that ActiveRecord's batch finding is not a proper enumerable citizen. It is in Rails 4.1-beta.
-
2013-10-06 Learning Ruby with Tests (Part 2)
The second part expands on the code created in round 1 and fleshes out the existing Vehicle class. It introduces a new test helper, instance variables, explains predicates and the overrides Vehicle's initialize method.
-
2013-09-04 6 Things About Rails.vim I Didn't Know
I've been using the incredible Rails.vim plugin for almost three years. Looking into how to extend it with a particular feature, I found out that vim-rails 5.0 already had it. That and so much more I've been oblivious about…
-
2013-09-02 Learning Ruby with Tests (Part 1)
The first part covers a very basic class and a simple, home-made test framework, that actually doesn't deserve the name 'framework' at this stage, yet.
-
2013-07-25 The Chicken-and-Egg Problem of Encrypted Email
There are actually quite a few similarities between IPv6 deployment and getting more people to encrypt their email communication: people either don't care or have no one to talk to.
-
2013-06-23 Experiment: FreeBSD 9.1 IPv6-only installation
There is no doubt about FreeBSD's support for IPv6 in a dual stack environment. Curiosity got me and I underwent a self-experiment to see if you can install if without v4 at all.
-
2013-05-02 MySQL 5.5 on GNU/kFreeBSD Debian Squeeze (IPv6 only)
There is no IPv6 support in MySQL 5.1. Upgrading to v5.5 involves building packages from source on the kfreebsd-amd64 architecture. This article guides through the hazzle of doing so for a non-standard setup (ie. kfreebsd w/o IPv4)
-
2011-04-20 assert_select from String
Rails provides assert_select to check for specific contents in a rendered view. We can leverage the logic to make it work out of a rendered view context.
-
2011-04-01 HAProxy, X-HTTP-Forwarded-For and exposed exceptions
Having an application service instance on the same node as the HAproxy instance may expose critical data about your app's setup (e.g. filenames, libraries used). This article briefly describes how to avoid that.
-
2009-10-15 Postage for (secure) Emails
A provider of free personal SSL certificates for secure email communication shut down its service. What options are left? What do we allow it to cost?