diff options
author | Bjørn Forsman <bjorn.forsman@gmail.com> | 2017-10-08 15:35:47 +0200 |
---|---|---|
committer | Bjørn Forsman <bjorn.forsman@gmail.com> | 2017-10-14 15:29:02 +0200 |
commit | 0ff4bb5f875afe8eb208bbabb3f52dc29539d2bc (patch) | |
tree | 5057f780699fcd8ca99ce859ff25b79ea734120f /nixos/modules/virtualisation/brightbox-image.nix | |
parent | 415db05504cdf8422fd8b681fd1f1e91b920230a (diff) | |
download | nixlib-0ff4bb5f875afe8eb208bbabb3f52dc29539d2bc.tar nixlib-0ff4bb5f875afe8eb208bbabb3f52dc29539d2bc.tar.gz nixlib-0ff4bb5f875afe8eb208bbabb3f52dc29539d2bc.tar.bz2 nixlib-0ff4bb5f875afe8eb208bbabb3f52dc29539d2bc.tar.lz nixlib-0ff4bb5f875afe8eb208bbabb3f52dc29539d2bc.tar.xz nixlib-0ff4bb5f875afe8eb208bbabb3f52dc29539d2bc.tar.zst nixlib-0ff4bb5f875afe8eb208bbabb3f52dc29539d2bc.zip |
nixos: run parted with --script option
-s, --script: never prompts for user intervention Sometimes the NixOS installer tests fail when they invoke parted, e.g. https://hydra.nixos.org/build/62513826/nixlog/1. But instead of exiting right there, the tests hang until the Nix builder times out (and kills the build). With this change the tests would instead fail immediately, which is preferred. While at it, use "parted --script" treewide, so nobody gets build timeout due to parted error (or misuse). (Only nixos/ use it, and only non-interactive.) A few instances already use the short option "-s", convert them to long option "--short".
Diffstat (limited to 'nixos/modules/virtualisation/brightbox-image.nix')
-rw-r--r-- | nixos/modules/virtualisation/brightbox-image.nix | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/nixos/modules/virtualisation/brightbox-image.nix b/nixos/modules/virtualisation/brightbox-image.nix index 7f45f0f34f71..08bbcfd9d7c2 100644 --- a/nixos/modules/virtualisation/brightbox-image.nix +++ b/nixos/modules/virtualisation/brightbox-image.nix @@ -33,9 +33,9 @@ in } '' # Create partition table - ${pkgs.parted}/sbin/parted /dev/vda mklabel msdos - ${pkgs.parted}/sbin/parted /dev/vda mkpart primary ext4 1 ${diskSize} - ${pkgs.parted}/sbin/parted /dev/vda print + ${pkgs.parted}/sbin/parted --script /dev/vda mklabel msdos + ${pkgs.parted}/sbin/parted --script /dev/vda mkpart primary ext4 1 ${diskSize} + ${pkgs.parted}/sbin/parted --script /dev/vda print . /sys/class/block/vda1/uevent mknod /dev/vda1 b $MAJOR $MINOR |