]> gitweb.fluxo.info Git - hydra.git/commitdiff
Fix: cryptsetup and parted issues
authorSilvio Rhatto <rhatto@riseup.net>
Thu, 25 Feb 2021 22:22:26 +0000 (19:22 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Thu, 25 Feb 2021 22:22:26 +0000 (19:22 -0300)
share/hydractl/provision

index 5766c5274a20cdc74c7fef187282cab07b2ed6d0..2793e11030e0b7cd6109c39099264d0f36eb9b37 100755 (executable)
@@ -51,7 +51,11 @@ function hydra_provision_lvcreate {
 # Cryptsetup wrapper.
 function hydra_cryptsetup {
   if [ ! -z "$1" ] && [ -b "$1" ]; then
-    hydra_sudo_run cryptsetup --cipher aes-xts-plain64:sha256 --key-size 512 --hash sha512 --iter-time 5000 --use-random -y -q luksFormat $1
+    # Run cryptsetup with custom parameters
+    #hydra_sudo_run cryptsetup --cipher aes-xts-plain64:sha256 --key-size 512 --hash sha512 --iter-time 5000 --use-random -y -q luksFormat $1
+
+    # Run cryptsetup mostly with defaults
+    hydra_sudo_run cryptsetup --use-random -y -q luksFormat $1
   fi
 }
 
@@ -230,9 +234,9 @@ else
   #     https://bugs.launchpad.net/ubuntu/+source/parted/+bug/1270203
   #     https://techtitbits.com/2018/12/using-parteds-resizepart-non-interactively-on-a-busy-partition/
   #     https://serverfault.com/questions/870594/resize-partition-to-maximum-using-parted-in-non-interactive-mode
-  #hydra_sudo_run parted -s -- $device mkpart non-fs ${start}s ${bios_grub_end}s
+  hydra_sudo_run parted -s -- $device mkpart non-fs ${start}s ${bios_grub_end}s
   #hydra_sudo_run parted -s ---pretend-input-tty -- $device mkpart non-fs ${start}s ${bios_grub_end}s Yes
-  hydra_sudo_run parted $device mkpart non-fs ${start}s ${bios_grub_end}s Yes Ignore quit
+  #hydra_sudo_run parted $device mkpart non-fs ${start}s ${bios_grub_end}s Yes Ignore quit
   #hydra_sudo_run parted -s ---pretend-input-tty $device <<EOF
 #mkpart non-fs ${start}s ${bios_grub_end}s
 #Yes