Change > to >>

Item should be added to /etc/dracut.conf.d/10-crypt.conf ,
 rather than be overwritten

 Issue #29
This commit is contained in:
Suikan 2021-07-28 08:22:45 +09:00
parent 2a7d5ff125
commit 95820a63d7
3 changed files with 6 additions and 5 deletions

View file

@ -28,10 +28,10 @@ function chrooted_job() {
echo "...Adding LUKS volume info to /etc/crypttab."
echo "${CRYPTPARTNAME} UUID=$(blkid -s UUID -o value ${DEV}${CRYPTPARTITION}) /etc/luks/boot_os.keyfile luks,discard" >> /etc/crypttab
# Add key file to the list of the intems in initfsram.
# Add key file to the list of the intems in initramfs.
# See https://man7.org/linux/man-pages/man5/dracut.conf.5.html for details.
echo "...Directing to include keyfile into the initfsram"
echo 'install_items+=" /etc/luks/boot_os.keyfile /etc/crypttab " ' > /etc/dracut.conf.d/10-crypt.conf
echo "...Directing to include keyfile into the initramfs"
echo 'install_items+=" /etc/luks/boot_os.keyfile /etc/crypttab " ' >> /etc/dracut.conf.d/10-crypt.conf
# Finally, update the ramfs initial image with the key file.
echo "...Upadting initramfs."