summaryrefslogtreecommitdiffstats
path: root/abs/core-testing/LinHES-config
diff options
context:
space:
mode:
authorJames Meyer <james.meyer@operamail.com>2009-01-26 21:04:08 (GMT)
committerJames Meyer <james.meyer@operamail.com>2009-01-26 21:04:08 (GMT)
commit438092055547037abd985ddec83cfe06551e62a6 (patch)
tree6b01b86e7e3700ee3f93854db4cda95a870184cf /abs/core-testing/LinHES-config
parent8977c61f73edfaafb7fb84f1dc107d4725725c6c (diff)
downloadlinhes_pkgbuild-438092055547037abd985ddec83cfe06551e62a6.zip
linhes_pkgbuild-438092055547037abd985ddec83cfe06551e62a6.tar.gz
linhes_pkgbuild-438092055547037abd985ddec83cfe06551e62a6.tar.bz2
Stop mysql from being installed on a FE only upgrade.
Diffstat (limited to 'abs/core-testing/LinHES-config')
-rwxr-xr-xabs/core-testing/LinHES-config/PKGBUILD2
-rwxr-xr-xabs/core-testing/LinHES-config/install_proxy.sh54
2 files changed, 29 insertions, 27 deletions
diff --git a/abs/core-testing/LinHES-config/PKGBUILD b/abs/core-testing/LinHES-config/PKGBUILD
index 28a67f0..1341ab2 100755
--- a/abs/core-testing/LinHES-config/PKGBUILD
+++ b/abs/core-testing/LinHES-config/PKGBUILD
@@ -1,6 +1,6 @@
pkgname=LinHES-config
pkgver=1.0
-pkgrel=224
+pkgrel=225
conflicts=(MythVantage-config MythVantage-config-dev LinHES-config-dev )
pkgdesc="Install and configure your system"
depends=(bc libstatgrab mysql-python expect curl dnsutils parted sg3_utils nmbscan )
diff --git a/abs/core-testing/LinHES-config/install_proxy.sh b/abs/core-testing/LinHES-config/install_proxy.sh
index 2dd8666..75ca6f0 100755
--- a/abs/core-testing/LinHES-config/install_proxy.sh
+++ b/abs/core-testing/LinHES-config/install_proxy.sh
@@ -396,42 +396,44 @@ function upgrade () {
#wrap this in a network check_network, no need to update the db if the import worked.
##### do I need to start mysql?
/etc/rc.d/mysqld stop
- echo $CMDLINE | grep -q clean_upgrade
- status=$?
- if [ $status = 0 ]
+ if [ $SystemType = "Master_backend" -o $SystemType = "Standalone" ]
then
- #new db as part of clean upgrade
- echo "--------------------------------"
- echo "clean upgrade installing new database"
- echo "--------------------------------"
- chroot "$mountpoint" "$MV_ROOT/bin/install_db_chroot.sh" |tee /tmp/chrootdb.out
- echo "############################################"
- echo "End Installing new database/clean"
- echo "############################################"
- else
- #proceed as normal
- if [ -f "$mountpoint"/$BACKUPFILE ]
+ echo $CMDLINE | grep -q clean_upgrade
+ status=$?
+ if [ $status = 0 ]
then
+ #new db as part of clean upgrade
echo "--------------------------------"
- echo "Restoring database with $BACKUPFILE"
+ echo "clean upgrade installing new database"
echo "--------------------------------"
- chroot "$mountpoint" "$MV_ROOT/bin/restore_km_db_chroot.sh" "$BACKUPFILE" |tee /tmp/chrootdb_km.out
+ chroot "$mountpoint" "$MV_ROOT/bin/install_db_chroot.sh" |tee /tmp/chrootdb.out
echo "############################################"
- echo "End Restoring database"
+ echo "End Installing new database/clean"
echo "############################################"
else
- echo "--------------------------------"
- echo "Couldn't find backup file, installing new database"
- echo "--------------------------------"
- touch /tmp/.upgrade_db_failed
- chroot "$mountpoint" "$MV_ROOT/bin/install_db_chroot.sh" |tee /tmp/chrootdb.out
- echo "############################################"
- echo "End Installing new database"
- echo "############################################"
+ #proceed as normal
+ if [ -f "$mountpoint"/$BACKUPFILE ]
+ then
+ echo "--------------------------------"
+ echo "Restoring database with $BACKUPFILE"
+ echo "--------------------------------"
+ chroot "$mountpoint" "$MV_ROOT/bin/restore_km_db_chroot.sh" "$BACKUPFILE" |tee /tmp/chrootdb_km.out
+ echo "############################################"
+ echo "End Restoring database"
+ echo "############################################"
+ else
+ echo "--------------------------------"
+ echo "Couldn't find backup file, installing new database"
+ echo "--------------------------------"
+ touch /tmp/.upgrade_db_failed
+ chroot "$mountpoint" "$MV_ROOT/bin/install_db_chroot.sh" |tee /tmp/chrootdb.out
+ echo "############################################"
+ echo "End Installing new database"
+ echo "############################################"
+ fi
fi
fi
-
if [ -f /tmp/etc/KnoppMyth-version ]
then
chroot "$mountpoint" $MV_ROOT/bin/restore_default_settings.sh -c restore -t hostsettings