be521bdec6
Export FS_TYPE from img-defaults and use it to remove hard-coded defaults in the debootstrap mounting. Also, cleanup the suse element as it should have access to the exported variable. Change-Id: Ie9b671ca9336060a5ad294be48aa7eff442bf066 Signed-off-by: Paul Belanger <pabelanger@redhat.com>
22 lines
628 B
Bash
Executable file
22 lines
628 B
Bash
Executable file
#!/bin/bash
|
|
# The base image created by kiwi does not contain an initrd so create one
|
|
# here.
|
|
|
|
if [ ${DIB_DEBUG_TRACE:-0} -gt 0 ]; then
|
|
set -x
|
|
fi
|
|
set -eu
|
|
set -o pipefail
|
|
|
|
# This is to tell mkinitrd to include the right tools for the root filesystem
|
|
# that will actually be used for the final image. This is likely something
|
|
# different than what the chroot is currently on (which might currently be a
|
|
# tmpfs even).
|
|
echo "rootfstype=$FS_TYPE" > /etc/sysconfig/initrd
|
|
|
|
# openSuse mkinitrd requires a valid root device be in fstab.
|
|
sed -i 's/vda1/sda1/' /etc/fstab
|
|
mkinitrd -A -B
|
|
|
|
# And cleanup again
|
|
rm /etc/sysconfig/initrd
|