|
|
|
@ -34,7 +34,7 @@ rmdir mountpoint
|
|
|
|
|
|
|
|
|
|
should_install_grub() {
|
|
|
|
|
case $architecture in
|
|
|
|
|
armhf|arm64)
|
|
|
|
|
armhf|arm64|s390x)
|
|
|
|
|
return 1
|
|
|
|
|
;;
|
|
|
|
|
*)
|
|
|
|
@ -56,5 +56,30 @@ if should_install_grub; then
|
|
|
|
|
rmdir mountpoint
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
if [ "$architecture" = "s390x" ]; then
|
|
|
|
|
# Do ZIPL install bits
|
|
|
|
|
mkdir mountpoint
|
|
|
|
|
mount_partition "${rootfs_dev_mapper}" mountpoint
|
|
|
|
|
|
|
|
|
|
# Write out cloudy zipl.conf for future kernel updates
|
|
|
|
|
cat << EOF > mountpoint/etc/zipl.conf
|
|
|
|
|
# This has been modified by the cloud image build process
|
|
|
|
|
[defaultboot]
|
|
|
|
|
default=ubuntu
|
|
|
|
|
|
|
|
|
|
[ubuntu]
|
|
|
|
|
target = /boot
|
|
|
|
|
image = /boot/vmlinuz
|
|
|
|
|
ramdisk = /boot/initrd.img
|
|
|
|
|
parameters = root=LABEL=cloudimg-rootfs
|
|
|
|
|
EOF
|
|
|
|
|
|
|
|
|
|
# Create bootmap file
|
|
|
|
|
mountpoint/sbin/zipl -V --image=mountpoint/boot/vmlinuz --ramdisk=mountpoint/boot/initrd.img --parameters='root=LABEL=cloudimg-rootfs' --target=mountpoint/boot/ --targetbase=/dev/loop0 --targettype=SCSI --targetblocksize=512 --targetoffset=2048
|
|
|
|
|
|
|
|
|
|
umount_partition mountpoint
|
|
|
|
|
rmdir mountpoint
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
clean_loops
|
|
|
|
|
trap - EXIT
|
|
|
|
|