mirror of
https://github.com/systemd/systemd.git
synced 2026-08-04 07:00:28 +00:00
repart: Generate fstab and crypttab late
The immediate need for the change is to allow to capture the expected LUKS volume key hash and record it to the generated crypttab but it also seems to make sense to not generate crypttab/fstab before we know that partition creation succeeded as fstab/crypttab entries are bogus otherwise.
This commit is contained in:
@@ -10719,14 +10719,6 @@ static int run(int argc, char *argv[]) {
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
r = context_fstab(context);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
r = context_crypttab(context);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
r = context_update_verity_size(context);
|
||||
if (r < 0)
|
||||
return r;
|
||||
@@ -10782,6 +10774,14 @@ static int run(int argc, char *argv[]) {
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
r = context_fstab(context);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
r = context_crypttab(context);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
(void) context_dump(context, /* late= */ true);
|
||||
|
||||
context_disarm_auto_removal(context);
|
||||
|
||||
Reference in New Issue
Block a user