[naemon-dev] Patch: Thruk -> reports2 -> Render.pm (hard-coded url-path)

Dragan Sekerovic dragan.sekerovic at onestep2.at
Wed Sep 17 14:34:01 CEST 2014


Hi naemon-dev list,

during the implementation of Naemon into tactus I figured out a problem within the Render.pm module of Thruk (problem: url-path is hard-coded).
This is a problem if Thruk is not deployed to the default path ‘/thruk’ (as it is the case with the bundled Thruk in Naemon (tested with Naemon 0.8.1_20140906).

To get this solved I patched Render.pm. Please find my patch attached.

The patch presupposes the existence of $c->config->{'product_prefix’}.
Maybe the default value should be set to “thruk” if not configured through thruk.conf (as it is the case in Naemon).

BTW: rewriting the url (Apache RewriteRule) does not solve the problem.
# redirect /thruk to new url, as the pkgs conflict anyway, this help migrating...
RewriteRule ^/thruk(.*)$             /naemon$1 [R=302,L]

Last but not least:
I’m Dragan Sekerovic, working for oneStep2 (Austria). We deliver monitoring and management solutions and services to national and international customers.
Some days ago I decided to replace Nagios with Naemon in tactus. Naemon and Thruk are awesome tools!!

Greetings from Austria,
Dragan


-------------- next part --------------
A non-text attachment was scrubbed...
Name: Render.pm.patch
Type: application/octet-stream
Size: 2425 bytes
Desc: not available
URL: <https://www.monitoring-lists.org/archive/naemon-dev/attachments/20140917/a2596b35/attachment.obj>
-------------- next part --------------



-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 496 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <https://www.monitoring-lists.org/archive/naemon-dev/attachments/20140917/a2596b35/attachment.sig>


More information about the Naemon-dev mailing list