allow to configure fstab-file
[util-vserver.git] / util-vserver / scripts / vserver-build.functions.apt
index ce86246..3d9e3af 100644 (file)
@@ -50,6 +50,14 @@ function initFilesystemApt
     mkdir -p "$PKGCFGDIR"/apt/{etc,archives/partial,cache,state/lists/partial}
     
     populateDirectory "$PKGCFGDIR/apt/etc" \
+       "$DISTRIBDIR/defaults/apt" \
        "$DISTRIBDIR/$DISTRIBUTION/apt" \
        "$CONFDIR/.distributions/$DISTRIBUTION/apt"
+
+    local f="$PKGCFGDIR"/apt/etc/apt.conf
+    if test -e "$f"; then
+       sed -e "s!@APTETCDIR@!$PKGCFGDIR/apt/etc!g" "$f" >"$f.tmp"
+       cmp -s "$f" "$f.tmp" || cat "$f.tmp" >"$f"
+       rm -f "$f.tmp"
+    fi
 }