ansible : pushing results to a database with a webhook

Viewed 57

I want to put my ansible results into a database.

I made a simple php webpage that listen for post data : server name, number of updates to install, etc and write it into a mysql database for later use (with grafana)

---> How can I make my ansible-playbook make a http post from the ansible server to save results?

I have seen uri but looks to work from the client. Maybe callback plugin but did not seen a simple http plugin.

an idea??

Thanks

1 Answers

You should try ansible-cmdb for this. It has options to store Ansible's output in the form of HTML, CSV, SQL, etc.

Option --template sql is available which is helpful in exporting to MySQL Database.

Related