Project

General

Profile

« Previous | Next » 

Revision b2a63751

Added by Greg Sutcliffe about 11 years ago

Add logfile to command ouput for install/upgrade

View differences:

debian/wheezy/foreman/foreman-mysql.postinst
. /usr/share/debconf/confmodule
LOGFILE='/var/log/foreman-install.log'
# if this script aborts with an error dpkg can
# hang if daemons have been started
trap db_stop EXIT
......
if [ ! -z "${DEBUG}" ]; then
bundle update --local
else
bundle update --local 2>&1 >/dev/null
bundle update --local 2>&1 >> $LOGFILE
fi
# Run a db:migrate if the user has created a dbfile
......
if [ ! -z "${DEBUG}" ]; then
su - foreman -s /bin/sh -c /usr/share/foreman/extras/dbmigrate || true
else
su - foreman -s /bin/sh -c /usr/share/foreman/extras/dbmigrate >/dev/null 2>&1 || true
su - foreman -s /bin/sh -c /usr/share/foreman/extras/dbmigrate >> $LOGFILE 2>&1 || true
fi
fi

Also available in: Unified diff