]> git.donarmstrong.com Git - dsa-puppet.git/blobdiff - modules/porterbox/files/schroot-dsa/config
dsa schroot config: use {fstab,copyfiles,nssdatabases} from schroot/dsa if available
[dsa-puppet.git] / modules / porterbox / files / schroot-dsa / config
index c94c6b3640e52d54a17fb5c11574fe1cc76232f0..ba94f6fedcd993614c178ec56745eb3b388256cf 100644 (file)
@@ -5,20 +5,28 @@
 ## USE: git clone git+ssh://$USER@puppet.debian.org/srv/puppet.debian.org/git/dsa-puppet.git
 ##
 
-. "/etc/schroot/default/config"
+FSTAB="/etc/schroot/dsa/fstab"
+[ -e "$FSTAB" ] || FSTAB="/etc/schroot/default/fstab"
+
+COPYFILES="/etc/schroot/dsa/copyfiles"
+[ -e "$COPYFILES" ] || COPYFILES="/etc/schroot/default/copyfiles"
+
+NSSDATABASES="/etc/schroot/dsa/nssdatabases"
+[ -e "$NSSDATABASES" ] || NSSDATABASES="/etc/schroot/default/nssdatabases"
+
 
 # added by weasel:
 if [ "$CHROOT_SESSION_PURGE" = "true" ]; then
     case $CHROOT_DESCRIPTION in
         "["*-*_*-dchroot"]"*)
-            chroot_type="$CHROOT_DESCRIPTION"; chroot_type="${chroot_type#[}"; chroot_type="${chroot_type%%]*}"
+            chroot_type="$CHROOT_DESCRIPTION"; chroot_type="${chroot_type#\[}"; chroot_type="${chroot_type%%]*}"
             suitevariant_arch_tuple="${chroot_type%%-dchroot-*}"
             suitevariant=${suitevariant_arch_tuple%_*}
             SUITE_BASE=${suitevariant%-*}
             SUITE_VARIANT=${suitevariant##*-}
         ;;
         "["*_*-dchroot"]"*)
-            chroot_type="$CHROOT_DESCRIPTION"; chroot_type="${chroot_type#[}"; chroot_type="${chroot_type%%]*}"
+            chroot_type="$CHROOT_DESCRIPTION"; chroot_type="${chroot_type#\[}"; chroot_type="${chroot_type%%]*}"
             SUITE_BASE="${chroot_type%%_*}"
         ;;
         *)