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/lib | |
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/lib')
-rw-r--r-- | nixos/lib/make-disk-image.nix | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/nixos/lib/make-disk-image.nix b/nixos/lib/make-disk-image.nix index d4b2e338c3ef..9fa848301f60 100644 --- a/nixos/lib/make-disk-image.nix +++ b/nixos/lib/make-disk-image.nix @@ -80,7 +80,7 @@ let truncate -s ${toString diskSize}M $diskImage ${if partitioned then '' - parted $diskImage -- mklabel msdos mkpart primary ext4 1M -1s + parted --script $diskImage -- mklabel msdos mkpart primary ext4 1M -1s offset=$((2048*512)) '' else '' offset=0 |