Revert "units: add initrd-cryptsetup.target"
This reverts commit 6c5496c492.
sysinit.target is shared between the initrd and the host system. Pulling in
initrd-cryptsetup.target into sysinit.target causes the following warning at
boot:
Oct 27 10:42:30 workstation-uefi systemd[1]: initrd-cryptsetup.target: Starting requested but asserts failed.
Oct 27 10:42:30 workstation-uefi systemd[1]: Assertion failed for initrd-cryptsetup.target.
This commit is contained in:
@@ -455,16 +455,10 @@ static int create_disk(
|
||||
}
|
||||
}
|
||||
|
||||
const char *target;
|
||||
if (in_initrd())
|
||||
target = "initrd-cryptsetup.target";
|
||||
else if (netdev)
|
||||
target = "remote-cryptsetup.target";
|
||||
else
|
||||
target = "cryptsetup.target";
|
||||
|
||||
if (!nofail)
|
||||
fprintf(f, "Before=%s\n", target);
|
||||
fprintf(f,
|
||||
"Before=%s\n",
|
||||
netdev ? "remote-cryptsetup.target" : "cryptsetup.target");
|
||||
|
||||
if (password && !keydev) {
|
||||
r = print_dependencies(f, password);
|
||||
@@ -527,7 +521,8 @@ static int create_disk(
|
||||
return log_error_errno(r, "Failed to write unit file %s: %m", n);
|
||||
|
||||
if (!noauto) {
|
||||
r = generator_add_symlink(arg_dest, target,
|
||||
r = generator_add_symlink(arg_dest,
|
||||
netdev ? "remote-cryptsetup.target" : "cryptsetup.target",
|
||||
nofail ? "wants" : "requires", n);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
Reference in New Issue
Block a user