Here's a bootstrap script for travis environments.

There are two sublties about it.

First, the hostname is long (about 39 characters), which is long
enough to exercise a bug in ntp in 12.04.  We pursue a standard
workaround of moving a certain file out of the way while installing.

Second, the DNS/reverse DNS lookup for does not work out of the box
for the usual machine names.  Unfortunately this exercises a known
issue in HDFS.  So we rewrite /etc/hosts to something minimal/sane.

See also
https://bugs.launchpad.net/ubuntu/+source/ntp/+bug/971314/comments/16
http://stackoverflow.com/q/4730148/580412