Various fixes from code review.

Cleaning indices; removing superfluous apt-get update; adding debug
messages; adding better output name
sil2100/enable-universe-none
Pat Viafore 6 years ago
parent 239012c608
commit 975a620e59
No known key found for this signature in database
GPG Key ID: 20C739856E05C9D1

@ -1,9 +1,11 @@
#!/bin/bash -ex #!/bin/bash -eux
# vi: ts=4 expandtab # vi: ts=4 expandtab
# #
# Generate KVM images # Generate KVM image
# #
echo "Building KVM image"
case ${SUBPROJECT:-} in case ${SUBPROJECT:-} in
minimized) minimized)
echo "Skipping minimized $0 builds" echo "Skipping minimized $0 builds"
@ -38,7 +40,6 @@ cleanup_kvm() {
} }
trap cleanup_kvm EXIT trap cleanup_kvm EXIT
chroot ${mount_d} apt-get update
divert_grub "${mount_d}" divert_grub "${mount_d}"
replace_kernel ${mount_d} "linux-kvm" replace_kernel ${mount_d} "linux-kvm"
@ -55,5 +56,9 @@ env DEBIAN_FRONTEND=noninteractive chroot "${mount_d}" apt-get \
env DEBIAN_FRONTEND=noninteractive chroot "${mount_d}" rm \ env DEBIAN_FRONTEND=noninteractive chroot "${mount_d}" rm \
-rf /boot/initrd.img-* /boot/initrd.img -rf /boot/initrd.img-* /boot/initrd.img
create_manifest ${mount_d} livecd.ubuntu-cpc.kvm.manifest # Remove indices
convert_to_qcow2 binary/boot/disk-kvm.ext4 livecd.ubuntu-cpc.kvm.img env DEBIAN_FRONTEND=noninteractive chroot "${mount_d}" apt-get \
clean
create_manifest ${mount_d} livecd.ubuntu-cpc.disk-kvm.manifest
convert_to_qcow2 binary/boot/disk-kvm.ext4 livecd.ubuntu-cpc.disk-kvm.img
Loading…
Cancel
Save