LUKS header and keyfile

This commit is contained in:
illiliti 2020-02-06 01:29:59 +03:00
parent f6a9226f88
commit 3f550778da

View File

@ -113,10 +113,20 @@ install_luks() {
# workaround for luks2 # workaround for luks2
install -s -m755 /usr/lib/libgcc_s.so.1 -t "${tmpdir}/usr/lib" install -s -m755 /usr/lib/libgcc_s.so.1 -t "${tmpdir}/usr/lib"
# block discard support
[ "$luks_discard" = 1 ] && luks_args="--allow-discards $luks_args" [ "$luks_discard" = 1 ] && luks_args="--allow-discards $luks_args"
# TODO detached header # copy luks header
# TODO keyfile [ -f "$luks_header" ] && {
install -m600 "$luks_header" "${tmpdir}/root/luks_header"
luks_args="--header=/root/luks_header $luks_args"
}
# copy luks keyfile
[ -f "$luks_keyfile" ] && {
install -m600 "$luks_keyfile" "${tmpdir}/root/luks_keyfile"
luks_args="--key-file=/root/luks_keyfile $luks_args"
}
} }
# install drivers # install drivers