Technical notes, my online memory

Thursday, September 17, 2015

Patching a python class attribute in a unit test using mock

›
I often want to change a class attribute in a unit test. While it is sort of documented in the official documentation , it's missing an ...
Friday, September 4, 2015

Snippet for verifying a SHA256 hash of a downloaded file in bash

›
This snippet will download openssl and verify the hash against a hard-coded value. This is useful on old operating systems (specifically Cen...
Tuesday, August 4, 2015

Provisioning a RHEL GCE machine with packer "sudo: sorry, you must have a tty to run sudo"

›
RedHat has long had an insane requiretty default for sudo , something that is fixed in later versions. Packer rightly doesn't set a tty ...
Thursday, July 30, 2015

Docker cheat sheet

›
Intended as a living document, just some basics for now. Build from the Dockerfile in the current directory and tag the image as "dem...

Docker vs. Vagrant

›
Docker and Vagrant are somewhat similar technologies, so what are their relative strengths and weaknesses and when should you choose one ove...

Changing the IP address of the docker0 interface on Ubuntu

›
Docker picks an address range for the docker0 range that it thinks is unused. Sometimes it makes a bad choice. The docs tell you that this c...
Friday, May 1, 2015

Measure windows cmd.exe command execution time

›
The *nix command 'time' is very useful for timing how long commands take. To do the same with the windows command line you have two...
‹
›
Home
View web version
Powered by Blogger.