Update example files for new dracut.

This commit is contained in:
Milan Broz
2012-07-10 19:59:44 +02:00
parent 91ba5742c6
commit 6462ee55d3
4 changed files with 24 additions and 2 deletions

View File

@@ -1,8 +1,8 @@
Example of simple dracut module for reencryption of system
LUKS drive on-the-fly.
Install in /usr/share/dracut/modules.d/90reencrypt, then
rebuild intramfs "with dracut -f -a reencrypt"
Install in /usr/[share|lib]/dracut/modules.d/90reencrypt, then
rebuild intramfs "with dracut -f -a reencrypt".
Dracut then recognize argument rd_REENCRYPT=name:size,
e.g. rd_REENCRYPT=sda2:52G means only 52G of device

View File

@@ -0,0 +1,22 @@
#!/bin/bash
check() {
[ -x /sbin/cryptsetup-reencrypt ] || return 1
return 255
}
depends() {
echo dm rootfs-block
return 0
}
installkernel() {
instmods dm_crypt =crypto
}
install() {
dracut_install cryptsetup-reencrypt
inst_hook cmdline 30 "$moddir/parse-reencrypt.sh"
inst_simple "$moddir"/reencrypt.sh /sbin/reencrypt
}