From f99160d868de5fa9adb1833351a9d5dcb6501ca0 Mon Sep 17 00:00:00 2001 From: tbrehm <t.brehm@ispconfig.org> Date: Wed, 10 Jun 2009 11:15:48 -0400 Subject: [PATCH] Updated Ubuntu 8.04 instructions Modified the update scripts to check if a download of the tar.gz has succeeded. --- server/scripts/update_from_svn.sh | 4 +++- server/scripts/ispconfig_update.php | 2 ++ docs/INSTALL_UBUNTU_8.04.txt | 2 +- server/scripts/update_from_tgz.sh | 17 ++++++++++++----- 4 files changed, 18 insertions(+), 7 deletions(-) diff --git a/docs/INSTALL_UBUNTU_8.04.txt b/docs/INSTALL_UBUNTU_8.04.txt index 4bedb14..5fe2c06 100644 --- a/docs/INSTALL_UBUNTU_8.04.txt +++ b/docs/INSTALL_UBUNTU_8.04.txt @@ -115,7 +115,7 @@ set docroot to: ### -docroot=/var/clients +docroot=/var/www/clients ### Change: application/x-httpd-php=php:/usr/bin/php-cgi to: diff --git a/server/scripts/ispconfig_update.php b/server/scripts/ispconfig_update.php index f18963f..f7615e1 100644 --- a/server/scripts/ispconfig_update.php +++ b/server/scripts/ispconfig_update.php @@ -95,11 +95,13 @@ $new_version = trim($new_version); if($new_version != ISPC_APP_VERSION) { passthru('/usr/local/ispconfig/server/scripts/update_from_tgz.sh'); + exit; } else { echo "There are no updates available for ISPConfig ".ISPC_APP_VERSION."\n"; } } else { passthru('/usr/local/ispconfig/server/scripts/update_from_svn.sh'); + exit; } diff --git a/server/scripts/update_from_svn.sh b/server/scripts/update_from_svn.sh index becd7e7..d8ed236 100644 --- a/server/scripts/update_from_svn.sh +++ b/server/scripts/update_from_svn.sh @@ -5,4 +5,6 @@ cd trunk/install php -q update.php cd /tmp -rm -rf /tmp/trunk \ No newline at end of file +rm -rf /tmp/trunk + +exit 0 \ No newline at end of file diff --git a/server/scripts/update_from_tgz.sh b/server/scripts/update_from_tgz.sh index 424a390..09dddeb 100644 --- a/server/scripts/update_from_tgz.sh +++ b/server/scripts/update_from_tgz.sh @@ -8,8 +8,15 @@ fi wget http://www.ispconfig.org/downloads/ISPConfig-3-stable.tar.gz -tar xvfz ISPConfig-3-stable.tar.gz -cd ispconfig3_install/install/ -php -q update.php -rm -rf /tmp/ispconfig3_install/install -rm -f ISPConfig-3-stable.tar.gz \ No newline at end of file +if [ -f ISPConfig-3-stable.tar.gz ] +then + tar xvfz ISPConfig-3-stable.tar.gz + cd ispconfig3_install/install/ + php -q update.php + rm -rf /tmp/ispconfig3_install/install + rm -f ISPConfig-3-stable.tar.gz +else + echo "Unable to download the update." +fi + +exit 0 \ No newline at end of file -- Gitblit v1.9.1