Programmatic usage of Nconf

User / Community contributed content: modifications, patches, extensions, modules, scripts etc.

Programmatic usage of Nconf

Postby chitrangada_rathore » Mon Aug 19, 2013 12:57

Hi

I am new to nconf and nagios. I need your guidance to create hosts, hostgroups and services on nconf programmatically.
In nagios we can edit the config files of the respective node like host/service/hostgroup etc. But in nconf i dont want to add or edit this information from the GUI inteface but from my script. Like, if i call a url and it adds the respective data in nconf's database.

So ultimately, is there any way to create/add host/service from a php script not by the beautiful frontend which nconf provide?

Thanks in advance.
chitrangada_rathore
 

Re: Programmatic usage of Nconf

Postby agargiulo » Sun Dec 29, 2013 22:07

Hi

You can query and add to the NConf database using the Perl API described here:
http://www.nconf.org/dokuwiki/doku.php? ... detail:api

However, as of this writing, the API does not provide functionality to edit / remove any items in the NConf DB. Only reading and adding.

Regards,
Angelo
User avatar
agargiulo
NConf developer
NConf developer
 
Posts: 725
Joined: Fri Mar 06, 2009 17:50
Location: Zurich, Switzerland


Return to Contributions

Who is online

Users browsing this forum: No registered users and 1 guest

cron