Use -y for upgrade in instsoft.GRMLBASE
[grml-live.git] / etc / grml / fai / config / hooks / instsoft.GRMLBASE
index 1b97e9b..2a00b39 100755 (executable)
@@ -43,13 +43,13 @@ if [ "$FAI_ACTION" = "softupdate" ] ; then
    # FAI softupdate does not execute upgrade, so let's do it on our own:
    $ROOTCMD apt-get update
    if [ -x $target/usr/bin/aptitude ] ; then
-      if $target/usr/bin/aptitude --help | grep safe-upgrade ; then
-         $ROOTCMD aptitude safe-upgrade
+      if strings $target/usr/bin/aptitude | grep safe-upgrade 1>/dev/null ; then
+         $ROOTCMD aptitude -y safe-upgrade
       else
-         $ROOTCMD aptitude upgrade
+         $ROOTCMD aptitude -y upgrade
       fi
    else
-      $ROOTCMD apt-get upgrade
+      $ROOTCMD apt-get -y upgrade
    fi
 
 else # no softupdate but fresh installation