Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
[dev.icinga.com #3869] make classic ui work standalone (drop icinga.cfg reading in favor of cmd pipe/status.dat/objects.cache/logs+archive) #1240
This issue has been migrated from Redmine: https://dev.icinga.com/issues/3869
Created by mfriedrich on 2013-03-17 10:20:33 +00:00
this is mainly a problem when putting icinga2 compat locations somewhere onto a dedicated classic ui interface, and setting everything via apache env variables just does not work. even further, tricking it with a dummy icinga.cfg with locations of
does work, but is still ugly. adding those 3 items directly to cgi.cfg (opt-in) will allow us to safely ignore icinga.cfg where no icinga is running.
2013-03-26 19:50:15 +00:00 by ricardo b1efafc
2013-04-13 12:37:52 +00:00 by (unknown) b805935
2013-04-13 13:14:11 +00:00 by (unknown) 530bca9
2013-04-13 13:34:01 +00:00 by (unknown) 9d3c943
Updated by mfriedrich on 2013-03-19 12:24:08 +00:00
since icinga2 will write compat log files too, that location should be standalone as well.
Updated by mfriedrich on 2013-04-13 11:51:05 +00:00
now copy the magic from a running icinga instance.
also tested the error case, when not having the standalone option enabled, if the icinga2 compat option trigger (they do not, but icinga.cfg will be used instead, nicely done!)
still, there's a small bug inside. if standalone is enable, but main_config_file is set, it will still try to read the values from icinga.cfg at first sight and ignores the rest.
commenting main_config_file solves the problem for now.
Updated by mfriedrich on 2013-04-13 12:56:03 +00:00
Updated by mfriedrich on 2013-04-13 13:18:19 +00:00
I've corrected the logic on reading the main config file, if the standalone option is set. once set, it should fully ignore the main config file and use the cgi.cfg instead. otherwise, it would be strange to have the standalone option set, but still reading the main config file.
if there's no cgi.cfg available then, it also throws the correct path :-)
Updated by mfriedrich on 2013-04-13 13:25:51 +00:00
this is helped by #3962 which allows you to set your own apache config file location with
already modular there.
added hidden 'make install-cgiconf' which gets invoked during 'make install-classicui-standalone'
fixed the STATEDIR creation in install-basic, and used that as fix for the install routine for standalone too (creating the log+archives and extcmdfiledir as well).
see #3963 - this works now out of the box, so nothing more needed than:
Updated by mfriedrich on 2013-04-15 10:13:39 +00:00
i've added a howto here: https://wiki.icinga.org/display/howtos/Setting+up+Icinga+Classic+UI+Standalone
so for now, i consider this resolved, thanks.