3 # Builds VServer reference image
5 # Mark Huang <mlhuang@cs.princeton.edu>
6 # Copyright (C) 2004-2006 The Trustees of Princeton University
8 # $Id: build.sh,v 1.4 2006/03/21 14:57:29 mlhuang Exp $
11 PATH=/sbin:/bin:/usr/sbin:/usr/bin
13 # In both a normal CVS environment and a PlanetLab RPM
14 # build environment, all of our dependencies are checked out into
15 # directories at the same level as us.
16 if [ -d ../build ] ; then
20 echo "Error: Could not find sources in either . or .."
26 # Release and architecture to install
32 echo "Usage: build.sh [OPTION]..."
33 echo " -r release Fedora release number (default: $releasever)"
34 echo " -a arch Fedora architecture (default: $basearch)"
35 echo " -h This message"
40 while getopts "r:a:h" opt ; do
55 vroot=$PWD/vservers/vserver-reference
56 install -d -m 755 $vroot
58 # Install vserver-reference system
59 mkfedora -v -r $releasever -a $basearch -g VServer $vroot
61 # This tells the Boot Manager that it is okay to update
62 # /etc/resolv.conf and /etc/hosts whenever the network configuration
63 # changes. Users are free to delete this file.
64 touch $vroot/etc/AUTO_UPDATE_NET_FILES