Ansible for OpenStack sanity-checks

Every time I do an OpenStack deployment, I make some mistake in a config file, which ends up being difficult to debug. It would be really great if I had a tool that can perform a bunch of sanity checks to try and spot anything inconsistent with the setup.

I think ansible’s check mode would be very well-suited to doing these kinds of sanity check. I can even envision modules that work only in check mode: for example, checking if the amount of unused disk is above a certain threshold, or checking the contents of certain database fields. I think this would be really valuable as we’re building the OpenStack stuff, to define these kinds of assertion checks. Examples include:

  • vlan_interface isn’t itself set to a vlan
  • /etc/nova/nova.conf is owned by the nova user
  • the interface column in the floating iP table matches the public_interface value in nova.conf
  • a glance server is specified for the compute nodes

Lorin

I do not want to overload the semantics of --check mode for this purpose.

There is already a syntax check flag.

In your case, you seem to have very very specific needs, so I'd
recommend a wrapper script before we create a whole-other scriptable
validation setup. Could be a project unto itself!

BTW, I'm suggesting *not* creating that other project, to be clear :slight_smile: