It's possible to use nagios with lighttpd instead of apache. Please add a corresponding USE-flag.
Created attachment 130323 [details, diff] nagios-core-2.9-r1.ebuild.patch This patch does the magic.
Created attachment 130324 [details] files/lighttpd_nagios.conf ... and this is the configuration-file for lighttpd
Maybe you want to add an apache2 USE-flag such that people who want to use nginx for example can simply do it
I plan to phase out the "noweb" use-flag w/ nagios-3 and instead support different http-servers via use-flags (apache2, lighttpd, ...). I'll try to add nagios-3 packages to my personal overlay within the next few days.
nagios-3 ebuilds with support for lighttpd (and apache of course :P) just added to my dev-overlay. I set up a test installation using lighty, works for me. Please test and report back! :)
Cool, seems to work here too after solving a couple of small things: When I tried to start nagios right after the installation, I got the following: [1193608375] Nagios 3.0b4 starting... (PID=5652) [1193608375] LOG VERSION: 2.0 [1193608375] Warning: Could not open object cache file '/var/nagios/objects.cache' for writing! [1193608375] Caught SIGSEGV, shutting down... ... I just changed the ownership of /var/nagios to solve this. You might also want to add a note to tell the user how he has to configure lighttpd ("include nagios.conf" and define an authentication method). The folder /etc/nagios is not w+rx and has the ownership nagios:nagios, but the user running the cgi is lighttpd:lighttpd, which resulted in the error "Error: Could not open CGI config file '/etc/nagios/cgi.cfg' for reading!". I changed the group for the folder to lighttpd. A better way (but only possible with lighttpd-1.5) is to run the cgi-process as a different user. And a question: why is the nagios.log-file in /var/nagios instead of /var/log/nagios? Thanks a lot, btw.
(In reply to comment #6) > ... I just changed the ownership of /var/nagios to solve this. ok, taken care of > You might also want to add a note to tell the user how he has to configure > lighttpd ("include nagios.conf" and define an authentication method). There's some info for apache, so some for lighty should be added - yeah. > The folder /etc/nagios is not w+rx and has the ownership nagios:nagios, but the > user running the cgi is lighttpd:lighttpd, which resulted in the error "Error: > Could not open CGI config file '/etc/nagios/cgi.cfg' for reading!". I changed > the group for the folder to lighttpd. There's also info for usage with apache already included, might make sense to make this wording a bit more general to cover both apache and ligthy. > And a question: why is the nagios.log-file in /var/nagios instead of > /var/log/nagios? Mostly historical reasons, I plan to adjust the installation path for nagios-3 according to FHS, i.e. install to /usr instead of /usr/nagios, moving nagios logfiles to /var/log/nagios/ is another thingy to be done. I'm going to push a new nagios-3.0_b5 ebuild to my overlay within the next few days which includes these changes.
This is fixed in CVS now. Note that nagios-3 ebuilds are still p.masked.
Created attachment 179330 [details, diff] mod_alias missing in default config in nagios.conf you have to load mod_alias for lighttpd to get alias.url working - this should be added to default config, lighttpd did not use this module by default
reopen
(In reply to comment #9) > Created an attachment (id=179330) [edit] > mod_alias missing in default config > > in nagios.conf you have to load mod_alias for lighttpd to get alias.url working > - this should be added to default config, lighttpd did not use this module by > default > fixed in 3.0.6-r1