X-Git-Url: https://code.grnet.gr/git/ganeti-local/blobdiff_plain/43ffd83959093e1cd56c45bf7eac1c86d77b8ee7..850c53f1cbab8c60c6be4964d10e8a2d3b3eb22b:/devel/build_chroot diff --git a/devel/build_chroot b/devel/build_chroot index aff8f3c..27be90f 100755 --- a/devel/build_chroot +++ b/devel/build_chroot @@ -5,7 +5,10 @@ : ${CONF_DIR:=/etc/schroot/chroot.d} : ${CHROOT_DIR:=/srv/chroot} : ${ALTERNATIVE_EDITOR:=/usr/bin/vim.basic} -# The value of DATA_DIR is read as well from the environment. +: ${CHROOT_FINAL_HOOK:=/bin/true} +# Additional Variables taken from the environmen +# DATA_DIR +# CHROOT_EXTRA_DEBIAN_PACKAGES #Automatically generated variables CHROOTNAME=$DIST_RELEASE-$ARCH @@ -116,7 +119,7 @@ in_chroot -- \ #Install selected packages from backports in_chroot -- \ - $APT_INSTALL -t squeeze-backports install \ + $APT_INSTALL -t squeeze-backports \ git \ vim @@ -209,10 +212,21 @@ in_chroot -- \ in_chroot -- \ $APT_INSTALL python-docutils debhelper quilt +# extra debian packages + +for package in $CHROOT_EXTRA_DEBIAN_PACKAGES +do in_chroot -- \ + $APT_INSTALL $package +done + #Set default editor in_chroot -- \ update-alternatives --set editor $ALTERNATIVE_EDITOR +# Final user hook + +in_chroot -- $CHROOT_FINAL_HOOK + rm -f $COMP_FILEPATH echo "Creating compressed schroot image..." cd $CHDIR