Better handling of hostname change for XMPP service

These changes should fix #9 and #33.

When changing the hostname, now for ejabberd.yml I only replace the hostname when it appears as an entry in the 'hosts' section. Also for the ejabberd backup database, I only replace the hostname in specified sections, and compare the formatting before/after the hostname to avoid false matches. (For example, if a user's name happens to match the old-hostname, it won't be accidentally replaced with the new-hostname.)

Use signals to trigger xmpp actions that need to run before and after changing the hostname. So instead of calling xmpp actions from the config module, the xmpp module listens for the appropriate signals then runs the actions.
With using `if line.startswith('var SITENAME')` we could force the new hostname to be set, even if the current configuration is different/wrong. This seems less error-prone to me, but I'm not familiar with setting up / configuring ejabberd or jwchat..