Skip to content

Commit 2f1a07e

Browse files
pq2enoch85
andauthored
Add here document block to 40_ (#2751)
Signed-off-by: pq2 <[email protected]> Co-authored-by: Daniel Hansson <[email protected]>
1 parent 6667035 commit 2f1a07e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

not-supported/tpm2-unlock.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,10 +99,11 @@ GRUB_PASS="$(echo -e "$PASSWORD\n$PASSWORD" | grub-mkpasswd-pbkdf2 | grep -oP 'g
9999
if [ -n "${PASSWORD##grub.pbkdf2.sha512.10000.}" ]
100100
then
101101
cat << GRUB_CONF > /etc/grub.d/40_custom
102-
102+
cat << EOF
103103
# Password-protect GRUB
104104
set superusers="grub"
105105
password_pbkdf2 grub $GRUB_PASS
106+
EOF
106107
GRUB_CONF
107108
# Allow to run the default grub options without requiring the grub password
108109
if ! grep -q '^CLASS=.*--unrestricted"' /etc/grub.d/10_linux && grep -q '^CLASS=.*"$' /etc/grub.d/10_linux

0 commit comments

Comments
 (0)