Add some more commonly expected packages.

sysv-rc and util-linux are used in the postinst scripts
of some packages, and so those packages won't install
if they aren't available.

sysv-rc contains update-rc.d, so any package that installs
a service would fail to install. Those packages are common
to install in to containers.

util-linux contains the getopt command which some scripts
expect to find.
This commit is contained in:
James Westby
2016-10-18 17:01:25 +01:00
committed by James Westby
parent 875e3592f7
commit 47e1cb91ef
3 changed files with 7 additions and 40 deletions
-38
View File
@@ -27,43 +27,6 @@ DIRS_TO_TRIM="/usr/share/man
/usr/share/info
"
PACKAGES_TO_EXCLUDE="acl
bsdutils
debconf-i18n
dmsetup
e2fslibs
e2fsprogs
gcc-4.8-base
init
initscripts
insserv
libcap2
libcap2-bin
libcryptsetup4
libdevmapper1.02.1
libkmod2
liblocale-gettext-perl
libmount1
libncursesw5
libprocps3
libsystemd0
libtext-charwidth-perl
libtext-iconv-perl
libtext-wrapi18n-perl
libudev1
mount
ncurses-bin
ncurses-base
procps
startpar
systemd
systemd-sysv
sysv-rc
sysvinit-utils
udev
util-linux
"
rootfsDir=$(mktemp -d)
echo "Building base in $rootfsDir"
DEBOOTSTRAP_DIR=$DEBOOTSTRAP_DIR debootstrap --variant container --foreign ${DIST} "$rootfsDir"
@@ -209,7 +172,6 @@ chmod 0755 "$rootfsDir/usr/sbin/install_packages"
echo "Trimming down"
chroot "$rootfsDir" dpkg --force-all -P $PACKAGES_TO_EXCLUDE
for DIR in $DIRS_TO_TRIM; do
rm -r "$rootfsDir/$DIR"/*
done