[25406] in Source-Commits

home help back first fref pref prev next nref lref last post

/svn/athena r24958 - trunk/debathena/scripts/installer

daemon@ATHENA.MIT.EDU (Jonathan D Reed)
Wed Feb 16 14:01:52 2011

Date: Wed, 16 Feb 2011 14:01:45 -0500
From: Jonathan D Reed <jdreed@MIT.EDU>
Message-Id: <201102161901.p1GJ1jEs008317@drugstore.mit.edu>
To: source-commits@mit.edu
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Author: jdreed
Date: 2011-02-16 14:01:44 -0500 (Wed, 16 Feb 2011)
New Revision: 24958

Modified:
   trunk/debathena/scripts/installer/install-debathena.sh
Log:
Don't fail catastrophically during PXE installs

Modified: trunk/debathena/scripts/installer/install-debathena.sh
===================================================================
--- trunk/debathena/scripts/installer/install-debathena.sh	2011-02-15 09:11:10 UTC (rev 24957)
+++ trunk/debathena/scripts/installer/install-debathena.sh	2011-02-16 19:01:44 UTC (rev 24958)
@@ -188,11 +188,16 @@
 output "Verifying machine is up to date..."
 pattern='^0 upgraded, 0 newly installed, 0 to remove'
 if ! apt-get --simulate --assume-yes dist-upgrade | grep -q "$pattern"; then
-     error "Your system is not up to date.  Proceeding with an install at"
-     error "this time could render your system unusable."
-     error "Please run 'apt-get dist-upgrade' as root or use the GUI update"
-     error "manager to ensure your system is up to date before continuing."
-     exit 1
+    if [ -n "$pxetype" ] ; then
+	output "Forcing an upgrade"
+	apt-get --assume-yes dist-upgrade
+    else 
+	error "Your system is not up to date.  Proceeding with an install at"
+	error "this time could render your system unusable."
+	error "Please run 'apt-get dist-upgrade' as root or use the GUI update"
+	error "manager to ensure your system is up to date before continuing."
+	exit 1
+    fi
 fi
 
 if ! hash aptitude >/dev/null 2>&1; then


home help back first fref pref prev next nref lref last post