Add a hook registering hosts into FreeIPA

Code by @stdweird, tested by @jrha and @stdweird at @stfc's premises.

Copied from piojo/AII-contrib. No incriminating history added here.