Author: | Ralph Bean <ralph.bean@gmail.com> |
---|
An example of a notification sent by func-inventory-notifier showing that the httpd service was started on the host lukacs.
To begin with, read about func and especially func-inventory if you don't yet know what they are.
Make sure you have func installed and working as you please.
Install func-inventory-notifier with:
pip install func-inventory-notifier
(or)
yum install func-inventory-notifier
Configure func-inventory notifier by editing
/etc/func/func-inventory-notifier.conf
Take it for a spin by running /usr/bin/func-inventory-notifier
It is particularly useful when scheduled to run regularly with cron. For instance, with a default installation of both func and func-inventory-notifier, a crontab entry like
0 * * * * /usr/bin/func-inventory-notifier 2>&1 | /bin/logger -t func
will wake up on the hour, monitor func-inventory's git repository, and if a change has happened, prepare and fire off an email to the root user. Any errors will be tossed to the system log for you to see (and report!)
We use it in conjunction with func's filetracker module to log all of our configurations changes in /etc: think yum repo configurations, httpd, passwd and shadow.