Ticket #142 (accepted enhancement)
Debian Lenny Package and other bug fixes
| Reported by: | pattieja1 | Owned by: | tdondich |
|---|---|---|---|
| Priority: | major | Milestone: | 1.4 |
| Component: | Lilac Configurator | Version: | 1.0.2 |
| Keywords: | deb bug fixes | Cc: |
Description
I'm not able to modify Ticket #76, otherwise I would have added this there.
I put together a deb package for Debian Lenny using the current stable release of lilac 1.0.2. To make the debianization process easier, I took the original tarball and created the following directories:
src/ - all the website code goes here
docs/ - the INSTALL, LICENSE and UPGRADING files go here.
I then created the debian/ subdirectory and populated the necessary control files using dh_make and it is then buildable using 'debhelper -tc' as the command from the lilac-1.0.2 directory.
The debian postinstall script does the necessary /etc/sudoers and /etc/php5/{apache2,cli}/php.ini config checks and changes to make sure that sudo is configured and the necessary php.ini tweaks are made.
It then tells the user to surf to http://theirhostname/lilac/install.php to finish setting up the install or doing an upgrade.
Things I tweaked/fixed in your code:
sqldata/seed.sql: I changed all your hard coded paths to be the nagios3 debian versions (so an export attempt should not complain about invalid paths)
importers/importers/nagios/Nagios{Host,Service}Importer.php: Fixed the issue where you were using &$entries in your foreach loop and then weren't unset($entries); before the next loop and so the first parameter from the next loop was wiping out the last entry just processed, which was causing check_command, etc. (or whatever was last) to not make it into the database.
See the lilac_1.0.2-12.diff.gz file for all the changes made. You will have to put your lilac-1.0.2 directory into the src, docs format for it to patch cleanly.
You can download the files from: http://www.japattie.info/lilac/
