~kirkland/maas/1287224

  • Committer: Dustin Kirkland
  • Date: 2014-08-05 18:35:26 UTC
  • Revision ID: dustin.kirkland@gmail.com-20140805183526-5plse38fgu65eq2i
Enable MAAS to produce friendly, pronounceable hostnames, LP: #1287224

Ship two culled word lists -- 1,315 adjectives, and 977 nouns.  This gives
us a possible 1,284,755 combinations of adjective-noun, which is more than
enough to cover any Class B, /12 network (255.240.0.0) and its 1,048,576
unique IP addresses.

You might notice that this model is quite similar to Ubuntu's friendly
release naming scheme, such as "Warty Warthog".

These word lists are shipped and installed in /etc/maas/adjectives.txt
and /etc/maas/nouns.txt, such that they are easily customized, edited,
or overwritten by any MAAS administrator.

The modified code updates the generate_hostname() hostname function
to try and generate an 'adjective-noun' hostname, but if any exception
occurs (such as a wordlist read exception), it will fall back to the
legacy 5-random-non-ambiguous-character hostname.

A test is included to ensure that all randomly generated hostnames
fit the model of "word hyphen word".  However, note that it's probably
not able to open and read the word lists, since they're installed on disk.
Filename Latest Rev Last Changed Committer Comment Size
..
acceptance 965.1.1 11 years ago Gavin Panella Binary build the current branch using the packagin Diff
bootstrap 632.2.1 11 years ago Gavin Panella Bundle distribute 0.6.24 in the tree to prevent a Diff
contrib 197.2.3 12 years ago Raphael Badin Fix settings, add packaging template file. Diff
docs 21.1.3 12 years ago Raphael Badin Generate static doc. Diff
etc 130.2.2 12 years ago Gavin Panella Config class for the provisioning server. Diff
logs 274.1.1 12 years ago Gavin Panella Update to txlongpoll 3.0.1. Diff
man 1366.1.1 11 years ago Gavin Panella Store generated man pages in the tree. Diff
media 246.5.7 12 years ago Gavin Panella Merged test-maas-separate-media-for-dev into test- Diff
required-packages 787.1.1 11 years ago Jeroen Vermeulen Systematize installation of required packages, and Diff
run 149.6.47 12 years ago Gavin Panella Control Apache via the service mechanism, calling Diff
scripts 199.1.3 12 years ago Andres Rodriguez move bin/ to scripts/ Diff
services 149.6.1 12 years ago Gavin Panella Use daemontools to start and stop pserv. Diff
src 1 12 years ago Raphael Badin Initial commit. Diff
templates 16.3.7 12 years ago Gavin Panella Templates for tests and modules. Diff
twisted 36.1.1 12 years ago Julian Edwards start the TAP for the provisioning server Diff
utilities 16.3.15 12 years ago Gavin Panella Borrow format-imports from Launchpad. Diff
.bzrignore 1817.1.5 10 years ago Gavin Panella Ignore .db.lock. 459 bytes Diff Download File
.ctags 362.6.7 12 years ago Gavin Panella Just exclude all JavaScript from tags. 57 bytes Diff Download File
buildout.cfg 2133.2.1 10 years ago Gavin Panella Split configuration tests into a new script, test. 4.5 KB Diff Download File
Symlink CHANGELOG 1681.3.2 10 years ago Julian Edwards have a separate CHANGELOG file .
HACKING.txt 2276.10.41 9 years ago Jason Hobbs Merge upstream. 15 KB Diff Download File
INSTALL.txt 2385.1.9 9 years ago Jason Hobbs merge upstream. 11.2 KB Diff Download File
LICENSE 2276.10.41 9 years ago Jason Hobbs Merge upstream. 34.2 KB Diff Download File
Makefile 2640.1.4 9 years ago Graham Binns Reverted an accidental commit to Makefile. 11.5 KB Diff Download File
MANIFEST.in 1501.3.1 10 years ago Gavin Panella Drop vdenv as unused. 247 bytes Diff Download File
README 2157.5.13 10 years ago Gavin Panella Remove trailing whitespace (and trigger re-diff in 1.2 KB Diff Download File
File setup.py 2602.1.6 9 years ago Julian Edwards fix location of maas-rsyslog in setup.py 5 KB Diff Download File
versions.cfg 2385.1.9 9 years ago Jason Hobbs merge upstream. 2.3 KB Diff Download File