From: Dan S. <dst...@gm...> - 2010-01-15 18:26:09
|
Please find attached a gzip'd tar archive containing two small patches to add display_name support to statusmap.cgi (statusmap.c) - so when you get a 2d statusmap via the CGI, you can add in more descriptive host "names". It is my hope that these patches could be added to a future release of Nagios. Thanks for the nifty software. PS: Here they are again as text, but I've attached them too anyway - one's easier for browsing, one's less likely to get messed up by MUA's and MTA's: --- cgi/statusmap.c.t 2010-01-15 10:04:33.000000000 -0800 +++ cgi/statusmap.c 2010-01-15 10:04:48.000000000 -0800 @@ -1791,7 +1791,7 @@ /* draw host name, status, etc. */ - draw_host_text(temp_host->name,x1+(DEFAULT_NODE_WIDTH/2),y1+DEFAULT_NODE_HEIGHT); + draw_host_text(temp_host->display_name,x1+(DEFAULT_NODE_WIDTH/2),y1+DEFAULT_NODE_HEIGHT); } /* we're creating HTML image map... */ --- html/docs/objectdefinitions.html.t 2010-01-15 10:14:16.000000000 -0800 +++ html/docs/objectdefinitions.html 2010-01-15 10:14:25.000000000 -0800 @@ -206,7 +206,7 @@ <tr> <td valign="top"><strong>display_name</strong>:</td> <td> -This directive is used to define an alternate name that should be displayed in the web interface for this host. If not specified, this defaults to the value you specify for the <i>host_name</i> directive. Note: The current CGIs do not use this option, although future versions of the web interface will. +This directive is used to define an alternate name that should be displayed in the web interface for this host. If not specified, this defaults to the value you specify for the <i>host_name</i> directive. Note: The current CGIs do not use this option, although future versions of the web interface will. At this time, only statusmap.cgi has been updated to use display_name. </td> </tr> <tr> @@ -650,7 +650,7 @@ <tr> <td valign="top"><strong>display_name</strong>:</td> <td> -This directive is used to define an alternate name that should be displayed in the web interface for this service. If not specified, this defaults to the value you specify for the <i>service_description</i> directive. Note: The current CGIs do not use this option, although future versions of the web interface will. +This directive is used to define an alternate name that should be displayed in the web interface for this service. If not specified, this defaults to the value you specify for the <i>service_description</i> directive. Note: The current CGIs do not use this option, although future versions of the web interface will. At this time, only statusmap.cgi has been updated to use display_name. </td> </tr> <tr> |