Add item to hostgroup overview page

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
marquetteu
Posts: 47
Joined: Tue Nov 13, 2012 12:08 pm

Add item to hostgroup overview page

Post by marquetteu »

Is there a way to add an icon/link to the hostgroup overview page? I know in the past with pnp4nagios i was able to add one (back in 2.x days).

I have found the action component and got it configured/tested, however, now i want to add the link to that component to the overview pages rather than the host detail page.

thanks!
Adam
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Add item to hostgroup overview page

Post by lmiltchev »

This functionality is not currently available in XI but according to our developers it would be easy to do. You are welcome to post a feature request on our public tracker here:

http://tracker.nagios.com

or I can post an internal feature request for you (if you want me to). Thanks!
Be sure to check out our Knowledgebase for helpful articles and solutions!
marquetteu
Posts: 47
Joined: Tue Nov 13, 2012 12:08 pm

Re: Add item to hostgroup overview page

Post by marquetteu »

feature request opened here:

http://tracker.nagios.com/view.php?id=738

If you are able to add any additional info that would help it would be appreciated.

Also -- would you be able to provide any hints/direction so that i would be able to potentially manually add it in while we wait for the feature request to be approved/added into XI?

thanks again!
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Add item to hostgroup overview page

Post by ssax »

There are three places that I could see adding an action link, which one are you looking to add it to? (see screenshot below)
hostgroup_overview_actions.png
You do not have the required permissions to view the files attached to this post.
marquetteu
Posts: 47
Joined: Tue Nov 13, 2012 12:08 pm

Re: Add item to hostgroup overview page

Post by marquetteu »

Since each host is going to have a unique link, #2 so that when i go to the hostgroup overview page i'll have the links for all the hosts
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Add item to hostgroup overview page

Post by lmiltchev »

I created an internal feature request (TASK ID 6175) and added links for our developers to this forum post and the feature request you posted on our public tracker.
Be sure to check out our Knowledgebase for helpful articles and solutions!
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Add item to hostgroup overview page

Post by ssax »

*** Note: This will get reverted if you upgrade, you should make backups/snapshots of the system and make sure they're good before making any modifications

To manually add it, you can edit this file:

Code: Select all

/usr/local/nagiosxi/html/includes/components/xicore/ajaxhelpers-status.inc.php
Then modify the link and text in the code below and add it after line 798:

Code: Select all

$host_name_cell .= "<a href='http://yoururl/$host_name'>YOURTEXT</a>";
That should get you what you want.
marquetteu
Posts: 47
Joined: Tue Nov 13, 2012 12:08 pm

Re: Add item to hostgroup overview page

Post by marquetteu »

is there a server side cache i need to clear? i restarted the services and cleared the browser cache but i don't see the new link anywhere
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Add item to hostgroup overview page

Post by ssax »

Oh, I apologize, I posted the wrong file, I've edited my post to reflect the correct file:

Code: Select all

/usr/local/nagiosxi/html/includes/components/xicore/ajaxhelpers-status.inc.php
Revert your changes to the other file and make the changes to this one.
Locked