Announcement

Collapse

GDPR - Your personal data is important

We value your personal data and ensure you that we will continue to secure the storage of the information you share with us regarding your use of this forum (email address, IP address, location, etc.) and only use them upon consent, and towards the purpose it’s intended for. Email us at community@centreon.com to request the update or deletion of your data.

If you wish to make sure you get all our latest tutorials, customer success stories, product updates and many great news, subscribe now to our monthly newsletter.

-------------------------------------------------------------------

Nous accordons beaucoup d’importance au traitement de vos données personnelles. Soyez assurés que les informations collectées dans le cadre de votre utilisation de ce forum (adresse email, IP de connexion, localisation, etc.) sont stockées de manière sécurisée et qu’elles ne sont utilisées que dans le cadre pour lequel elles sont été collectées. Pour toute demande de modification ou suppression de vos informations, écrivez-nous à community@centreon.com.

Si vous souhaitez recevoir tous nos tutoriels, retours d’expériences, nouveautés produit et bien d’autres actualités, (ré)abonnez-vous sans attendre à notre newsletter mensuelle !
See more
See less

Automate host addition / suppression in Centreon with Ansible (through CLAPI)

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Automate host addition / suppression in Centreon with Ansible (through CLAPI)

    Hi everyone,

    6 months ago, I have made a prototype of an Ansible module that uses CLAPI to help you automate the addition of hosts in your centreon server :
    • when the administrator create a virtual machine (with Ansible also ;-p), the host is registered inside Ansible hosts file
    • then he only has to launch the playbook for centreon on the whole hosts file, and only the newly added servers are imported in centreon

    So far it has allowed me to entirely automate my monitoring (with good templates) with Ansible. I now have a little less than 200 hosts, 10 templates or so (windows, esxi, vcenter, linux, ...), all automatically managed.

    You can get the code for the module on github (not yet ready for integration in Ansible code base) :
    Also, for french Readers, I've written a blog post about it, which explain why I had to create a module for this rather than juste using an Ansible call to CLAPI with the "shell" module.
    Hope this can be useful !
Working...
X