Customizing Nagios Web Front End

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
neworderfac33
Posts: 329
Joined: Fri Jul 24, 2015 11:04 am

Customizing Nagios Web Front End

Post by neworderfac33 »

Good afternoon,

I have been asked if it is possible to customize the web front end in such a way that only the "Host Groups" view is available (to prevent people from clicking on all the other views)

I suspect that this isn't possible without some modification to the Nagios Core application itself, but I'd be happy to be proved wrong!

Thanks in advance

Pete
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: Customizing Nagios Web Front End

Post by hsmith »

I don't know of a 'clean' way. However....


Disclaimer: You probably can / will break something by editing this:

Code: Select all

/usr/local/nagios/share/side.php 



I'll just leave it there in case :shock:
Former Nagios Employee.
me.
neworderfac33
Posts: 329
Joined: Fri Jul 24, 2015 11:04 am

Re: Customizing Nagios Web Front End

Post by neworderfac33 »

My God. It's full of stars..!
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Customizing Nagios Web Front End

Post by tmcdonald »

Not 100% what you're looking at, but it should be full of PHP and HTML code.
Former Nagios employee
neworderfac33
Posts: 329
Joined: Fri Jul 24, 2015 11:04 am

Re: Customizing Nagios Web Front End

Post by neworderfac33 »

Actually, that's EXACTLY what i was looking at.
I commented out the sections that I wanted by prefixing the code with !-- and ending it with -- thus:

Code: Select all

<li><a href="<?php echo $cfg["cgi_base_url"];?>/statusmap.cgi?host=all" target="<?php echo $link_target;?>">Map</a></li>
became:

Code: Select all

<!--li><a href="<?php echo $cfg["cgi_base_url"];?>/statusmap.cgi?host=all" target="<?php echo $link_target;?>">Map</a></li-->
I'm going to have a go with main.php now, to see what I can break in there!

Thanks very much indeed - this thread can now be closed.

Pete
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: Customizing Nagios Web Front End

Post by hsmith »

Glad to hear you didn't break it too bad :)
Former Nagios Employee.
me.
Locked