mirror of
https://github.com/nix-community/disko
synced 2024-11-10 06:14:14 +00:00
Fix problem with missing part. labels.
This commit is contained in:
parent
b54e2dc988
commit
fc6f863fe1
5 changed files with 6 additions and 0 deletions
|
@ -44,6 +44,7 @@ let
|
|||
${pkgs.systemdMinimal}/lib/systemd/systemd-udevd --daemon
|
||||
udevadm trigger --action=add
|
||||
udevadm settle
|
||||
partprobe
|
||||
|
||||
# populate nix db, so nixos-install doesn't complain
|
||||
export NIX_STATE_DIR=$TMPDIR/state
|
||||
|
|
|
@ -107,6 +107,7 @@ in
|
|||
# ensure /dev/disk/by-path/..-partN exists before continuing
|
||||
udevadm trigger --subsystem-match=block
|
||||
udevadm settle
|
||||
partprobe
|
||||
${lib.optionalString (partition.content != null) partition.content._create}
|
||||
'') sortedPartitions)}
|
||||
|
||||
|
|
|
@ -44,6 +44,7 @@
|
|||
"''${disk_devices[@]}"
|
||||
udevadm trigger --subsystem-match=block
|
||||
udevadm settle
|
||||
partprobe
|
||||
# for some reason mdadm devices spawn with an existing partition table, so we need to wipe it
|
||||
sgdisk --zap-all /dev/md/${config.name}
|
||||
${lib.optionalString (config.content != null) config.content._create}
|
||||
|
|
|
@ -93,6 +93,7 @@
|
|||
# ensure /dev/disk/by-path/..-partN exists before continuing
|
||||
udevadm trigger --subsystem-match=block
|
||||
udevadm settle
|
||||
partprobe
|
||||
${lib.optionalString partition.bootable ''
|
||||
parted -s ${config.device} -- set ${toString partition._index} boot on
|
||||
''}
|
||||
|
@ -102,6 +103,7 @@
|
|||
# ensure further operations can detect new partitions
|
||||
udevadm trigger --subsystem-match=block
|
||||
udevadm settle
|
||||
partprobe
|
||||
${lib.optionalString (partition.content != null) partition.content._create}
|
||||
'') config.partitions)}
|
||||
'';
|
||||
|
|
|
@ -52,6 +52,7 @@
|
|||
-V ${config.size}
|
||||
udevadm trigger --subsystem-match=block
|
||||
udevadm settle
|
||||
partprobe
|
||||
${lib.optionalString (config.content != null) config.content._create}
|
||||
'';
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue