[26014] in Source-Commits

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

Re: /svn/athena r25346 - trunk/debathena/scripts/installer

daemon@ATHENA.MIT.EDU (Geoffrey Thomas)
Tue Aug 2 11:17:43 2011

Date: Tue, 2 Aug 2011 11:17:36 -0400 (EDT)
From: Geoffrey Thomas <geofft@MIT.EDU>
To: Jonathan D Reed <jdreed@mit.edu>
cc: source-commits@mit.edu
In-Reply-To: <201108021300.p72D0jMV009352@drugstore.mit.edu>
Message-ID: <alpine.DEB.2.00.1108021117350.8909@tyger.mit.edu>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed

ACK

-- 
Geoffrey Thomas
geofft@mit.edu

On Tue, 2 Aug 2011, Jonathan D Reed wrote:

> Author: jdreed
> Date: 2011-08-02 09:00:45 -0400 (Tue, 02 Aug 2011)
> New Revision: 25346
>
> Modified:
>   trunk/debathena/scripts/installer/install-debathena.beta.sh
> Log:
> Check for a supported release _first_
>
> Modified: trunk/debathena/scripts/installer/install-debathena.beta.sh
> ===================================================================
> --- trunk/debathena/scripts/installer/install-debathena.beta.sh	2011-08-02 12:30:54 UTC (rev 25345)
> +++ trunk/debathena/scripts/installer/install-debathena.beta.sh	2011-08-02 13:00:45 UTC (rev 25346)
> @@ -42,6 +42,38 @@
>   exit 1
> fi
>
> +have_lsbrelease="$(dpkg-query -W -f '${Status}' lsb-release 2>/dev/null)"
> +if [ "$have_lsbrelease" != "install ok installed" ]; then
> +  echo "The installer requires the 'lsb-release' package to determine"
> +  echo "whether or not installation can proceed."
> +  ask "Is it ok to install this package now? [Y/n] " y
> +  if [ y = "$answer" ]; then
> +    if ! apt-get -qq update && apt-get -qqy install lsb-release; then
> +	error "Could not install lsb-release.  Try installing it manually."
> +	exit 1
> +    fi
> +  else
> +    error "Sorry, lsb-release is required.  Cannot continue."
> +    exit 1
> +  fi
> +fi
> +distro=`lsb_release -cs`
> +case $distro in
> +  lenny|squeeze)
> +    ;;
> +  hardy|intrepid|jaunty|karmic|lucid|maverick|natty)
> +    ubuntu=yes
> +    ;;
> +  *)
> +    error "Unsupported release codename: $distro"
> +    error "Sorry, Debathena does not support installation on this release at this time."
> +    error "(New releases may not be supported immediately after their release)."
> +    error "If you believe you are running a supported release or have questions,"
> +    error "please contact debathena@mit.edu"
> +    exit 1
> +    ;;
> +esac
> +
> echo "Welcome to the Debathena installer."
> echo ""
> echo "Please choose the category which best suits your needs.  Each category"
> @@ -232,26 +264,12 @@
>   apt-get -y install aptitude
> fi
>
> -output "Installing Debathena installer dependencies: lsb-release, wget, and dnsutils"
> -aptitude -y install lsb-release wget dnsutils
> +output "Installing Debathena installer dependencies: wget and dnsutils"
> +aptitude -y install wget dnsutils
> if [ yes = "$resolvconfhack" ]; then
>   output "Installing resolvconf ahead of time"
>   aptitude -y install resolvconf
> fi
> -distro=`lsb_release -cs`
> -case $distro in
> -lenny|squeeze)
> -  ;;
> -hardy|intrepid|jaunty|karmic|lucid|maverick|natty)
> -  ubuntu=yes
> -  ;;
> -*)
> -  error "Your machine seems to not be running a supported Debian/Ubuntu release."
> -  error "(New releases may not be supported immediately after their release)."
> -  error "If you believe you are running a supported release, contact debathena@mit.edu"
> -  exit 1
> -  ;;
> -esac
>
> if aptitude show openafs-modules-dkms > /dev/null; then
>   openafs_component=" openafs"
>
>

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