All modules now live in a subdirectory /modules.d. Each module is
self-contained -- it should contain everything that it will install
on the initrd. All modules must include a script named install, which
will be sourced by dracut. This script should do the actual file installation
using inst methods. The moddir variable will point to the full path to the
module dracut is currently working on.
As usual, this patch series applies on top of my previous patch series,
and is available as normalize-modules from http://git.fnordovax.org/dracut.
If the last character in the argument to search for is "=", then
getarg will echo all the text after the = as well as returning 0 or 1 depending
on whether or not the arg is found.
Otherwise, getarg will jsut return 0 if the exact test of the argument is found,
1 otherwise.
Modules are now responsible for loading their hooks into the initrd.
This should be all the structure we need to make it easy for things
to integrate with dracut -- now to document and test it all.
Any script placed in /pre-udev will be sourced just before udev starts
device scanning and loading.
Any script placed in /pre-mount will be sourced just before we try to
mount a root filesystem.
Any script placed in /pre-pivot will be sourced just before we switch to the
new root filesystem.
These hooks should be the minimum needed to add back plymouth and deal with
more advanced filesysem mounting needs (multipath, iscsi, nfs, nbd, etc.)
This is for tasks that should run after device discovery, but before
mounting the new rootfs. Things like cryptoroot and resume from hibernate
should go here.
Hooks are sourced, not executed as separate scripts.