Hi,
My goal is to use Centreon (the better Nagios monitoring system) and it's command line API to have the Salt Master do something (add the minion to the monitored hosts for example) after a state change on a minion.
for example, I just created a new linux host and registered the minion. Calling highstate then add apache, mysql and PHP on the minion.
For each of those actions, I would like the master to call the Centreon command line with options to :
- add the host
- add a http service monitoring
- add a mysql service monitoring...
I went through the docs and on IRC, and the solution may be in Events and Reactors. But the lack of documentation make it really difficult to try...
Let's work with the apache service. The state would be to install and start the pkg "httpd" (on CentOS).
Then, how would I have the minion to fire an event to the master so "service is started"
How would I have the master to listen to this event and take action ?
I will need the master to be able to gather some informations (the name and IP of the minion, the name of the service and maybe some other information) and run multiple command line commands with specific parameters to work on the Centreon side.
Anyone can help on this ?
Maybe i'm just going the wrong way ?
Thanks.