Files
calamares-settings-vesperos/scripts/bootloader-config
T
Jonathan Carter 34abde07b6 Fix security issue
2019-07-03 13:09:54 +00:00

19 lines
723 B
Bash
Executable File

#!/bin/bash
CHROOT=$(mount | grep proc | grep calamares | awk '{print $3}' | sed -e "s#/proc##g")
# Set secure permissions for the initramfs,
# the initramfs is re-generated later in the installation process
# so we only set the permissions without regenerating the initramfs now:
echo "UMASK=0077" > /etc/initramfs-tools/conf.d/initramfs-permissions
echo "Running bootloader-config..."
if [ -d /sys/firmware/efi/efivars ]; then
echo " * Installing grub-efi (uefi)..."
DEBIAN_FRONTEND=noninteractive chroot $CHROOT apt-get -y install grub-efi-amd64 cryptsetup keyutils
else
echo " * install grub... (bios)"
DEBIAN_FRONTEND=noninteractive chroot $CHROOT apt-get -y install grub-pc cryptsetup keyutils
fi