Use SUBPROJECT=minimized name instead of SUBPROJECT=minimize for consistency

core-include-dmsetup
Balint Reczey 7 years ago
parent b90b04a7b7
commit 88d854ffb5

@ -31,14 +31,14 @@ Expire-Date: 0
lb bootstrap "$@" lb bootstrap "$@"
if [ "$SUBPROJECT" = minimize ] \ if [ "$SUBPROJECT" = minimized ] \
&& ! Chroot chroot dpkg -l tzdata 2>&1 |grep -q ^ii; then && ! Chroot chroot dpkg -l tzdata 2>&1 |grep -q ^ii; then
# workaround for tzdata purge not removing these files # workaround for tzdata purge not removing these files
rm -f chroot/etc/localtime chroot/etc/timezone rm -f chroot/etc/localtime chroot/etc/timezone
fi fi
if [ "$SUBPROJECT" = minimize ]; then if [ "$SUBPROJECT" = minimized ]; then
# set up dpkg filters to skip installing docs on minimized system # set up dpkg filters to skip installing docs on minimizedd system
mkdir -p chroot/etc/dpkg/dpkg.cfg.d mkdir -p chroot/etc/dpkg/dpkg.cfg.d
cat > chroot/etc/dpkg/dpkg.cfg.d/excludes <<EOF cat > chroot/etc/dpkg/dpkg.cfg.d/excludes <<EOF
# Drop all man pages # Drop all man pages

@ -196,7 +196,7 @@ HWE_X_PACKAGES="xserver-xorg-hwe-16.04 xserver-xorg-video-all-hwe-16.04 xserver-
HWE_KERNEL_FLAVOUR="generic-hwe-16.04" HWE_KERNEL_FLAVOUR="generic-hwe-16.04"
HWE_SIGNED_KERNEL_PACKAGE="linux-signed-$HWE_KERNEL_FLAVOUR" HWE_SIGNED_KERNEL_PACKAGE="linux-signed-$HWE_KERNEL_FLAVOUR"
if [ "$SUBPROJECT" = minimize ]; then if [ "$SUBPROJECT" = minimized ]; then
OPTS="${OPTS:+$OPTS }--bootstrap-flavour=minimal" OPTS="${OPTS:+$OPTS }--bootstrap-flavour=minimal"
fi fi
@ -499,7 +499,7 @@ case $PROJECT in
;; ;;
ubuntu-cpc) ubuntu-cpc)
if [ "$SUBPROJECT" = minimize ]; then if [ "$SUBPROJECT" = minimized ]; then
add_task install cloud-image add_task install cloud-image
add_package install sudo add_package install sudo
else else

@ -116,7 +116,7 @@ if [ "${should_install_grub}" -eq 1 ]; then
rm mountpoint/tmp/device.map rm mountpoint/tmp/device.map
if [ "$SUBPROJECT" = minimize ] && [ -n "$partuuid" ]; then if [ "$SUBPROJECT" = minimized ] && [ -n "$partuuid" ]; then
echo "partuuid found for root device; forcing it in Grub" echo "partuuid found for root device; forcing it in Grub"
mkdir -p mountpoint/etc/default/grub.d mkdir -p mountpoint/etc/default/grub.d
echo "GRUB_FORCE_PARTUUID=$partuuid" >> mountpoint/etc/default/grub.d/40-force-partuuid echo "GRUB_FORCE_PARTUUID=$partuuid" >> mountpoint/etc/default/grub.d/40-force-partuuid

@ -61,7 +61,7 @@ install_grub() {
efi_boot_dir="/boot/efi/EFI/BOOT" efi_boot_dir="/boot/efi/EFI/BOOT"
chroot mountpoint mkdir -p "${efi_boot_dir}" chroot mountpoint mkdir -p "${efi_boot_dir}"
if [ "${SUBPROJECT:-}" = minimize ] && [ -n "$partuuid" ]; then if [ "${SUBPROJECT:-}" = minimized ] && [ -n "$partuuid" ]; then
# FIXME: code duplicated between 032-disk-image.binary # FIXME: code duplicated between 032-disk-image.binary
# and 033-disk-image-uefi.binary. We want to fix this to not # and 033-disk-image-uefi.binary. We want to fix this to not
# have initramfs-tools installed at all on these images. # have initramfs-tools installed at all on these images.

@ -89,7 +89,7 @@ _xchroot "${rootd}" sh -c 'sed -i "/^127.0.1.1/d" /etc/hosts'
_xchroot "${rootd}" sh -c 'rm -f /etc/ssh/ssh_host_[rd]sa_key*' _xchroot "${rootd}" sh -c 'rm -f /etc/ssh/ssh_host_[rd]sa_key*'
## -------------- ## --------------
if [ "${SUBPROJECT:-}" != minimize ]; then if [ "${SUBPROJECT:-}" != minimized ]; then
_xchroot "${rootd}" locale-gen en_US.utf8 _xchroot "${rootd}" locale-gen en_US.utf8
fi fi

Loading…
Cancel
Save