This file is one APT creates to make sure we don't "autoremove" our currently in-use kernel, which doesn't really apply to debootstraps/Docker images that don't even have kernels installed.
Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
| ... | ... |
@@ -49,6 +49,11 @@ chmod +x "$rootfsDir/usr/sbin/policy-rc.d" |
| 49 | 49 |
# shrink a little, since apt makes us cache-fat (wheezy: ~157.5MB vs ~120MB) |
| 50 | 50 |
( set -x; chroot "$rootfsDir" apt-get clean ) |
| 51 | 51 |
|
| 52 |
+# this file is one APT creates to make sure we don't "autoremove" our currently |
|
| 53 |
+# in-use kernel, which doesn't really apply to debootstraps/Docker images that |
|
| 54 |
+# don't even have kernels installed |
|
| 55 |
+rm -f "$rootfsDir/etc/apt/apt.conf.d/01autoremove-kernels" |
|
| 56 |
+ |
|
| 52 | 57 |
# Ubuntu 10.04 sucks... :) |
| 53 | 58 |
if strings "$rootfsDir/usr/bin/dpkg" | grep -q unsafe-io; then |
| 54 | 59 |
# force dpkg not to call sync() after package extraction (speeding up installs) |