#!/bin/sh #---------------------------------------------------------------------------- # Copyright (c) 2005 Sebastian Scholze # # Creation: 2005-05-17 schlotze # Last Update: $Id$ # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. #------------------------------------------------------------------------------ # include eislib . /var/install/include/eislib #testroot=/home/scholze/root testroot='' # configuration configuration=$testroot/etc/config.d/tomcat installfile=$testroot/var/run/tomcat.install deinstallfile=$testroot/var/install/deinstall/tomcat generated_conf=$configuration # check base version #installed_version=`/var/install/bin/check-version base 1.0.5` add_variables () { added=0 mecho -info "adding new variables..." if [ $added -eq 1 ] then mecho -info "... check your configuration for new parameter(s)!" else mecho -info "... nothing to do." fi mecho -info "...finished." } delete_variables () { deleted=0 mecho -info "deleting absolete variables..." if [ $deleted -eq 1 ] then mecho -info "... check your configuration for absolete parameter(s)!" else mecho -info "... nothing to do." fi mecho -info "...finished." } create_config () { mecho -info "updating/creating configuration..." { } > $generated_conf mecho -info "...finished." } # update configuration if [ -f $installfile ] then # previous configuration file exists . $installfile add_variables delete_variables # create_config anykey else mecho -error "no configuration $installfile found - exiting." fi