The setup scriptApril 05. 2010
Some Details of setup.shThe script setup.sh is used for installing and setting up Check_MK, including MK Livestatus and Multisite. Features of this script are:
Doing an updateUpdating Check_MK to a new version follows the same procedure as a new installation. But: since setup saved your settings in the file ~/.check_mk_setup.conf, instead of the autodetected or default values the settings from your previous setup will be used as default values. Only in cases where the new version introduces completely new settings, autodetection will take place. If you want to restart from scratch, then simply delete ~/.check_mk_setup.conf before calling setup.sh. If you know that you do not want to change any setting, you can call setup.sh with the option --yes. This is much the same as pressing enter at each question and confirm the installation with yes. Furthermore the procedure is completely silent and only ouputs something in case of a problem. Setup for packagersIf you are packaging Check_MK - say in an RPM or DEB package - you surely need to things:
The first one can simply be achieved by setting the environment variable DESTDIR to a directory. Just as usual with automake Makefiles, that directory will be automatically created. Here is an example: user@host> DESTDIR=/tmp/checkmk.root ./setup.sh --yes This will install Check_MK into the default paths, all prefixed with /tmp/checkmk.root, for example /tmp/checkmk.root/usr/bin/check_mk and so on. No file will be touched outside of your DESTDIR. Using DESTDIR also has some other effects useful while packaging:
But how can you tweak the installation paths then? Just put those settings usually found in ~/.check_mk_setup.conf into your environment. Here is an example where two of the default settings are overriden with custom values: user@host> export bindir=/usr/local/bin user@host> export enable_livestatus=no user@host> DESTDIR=/tmp/checkmk.root ./setup.sh --yes |
| |||||||||||||||||||||