From fca431d1316c4a9ad6846826bdf82a72d4879776 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Mon, 9 Jun 2014 14:03:11 -0300 Subject: Provision: use system's default arch in config --- share/hydractl/provision | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/share/hydractl/provision b/share/hydractl/provision index 59f9e4f..703806d 100755 --- a/share/hydractl/provision +++ b/share/hydractl/provision @@ -77,6 +77,14 @@ function hydra_provision_create_volume { # Make sure there is provision config. function hydra_provision_config { + local base_arch=`uname -m`; + + if [ "$base_arch" == "x86_64" ]; then + base_arch="amd64" + else + base_arch="i386" + fi + hydra_user_config interactive y "Interactive mode? (y/n)" hydra_user_config device /dev/sdb "Destination device" hydra_user_config device_label msdos "Device disk label" @@ -89,7 +97,7 @@ function hydra_provision_config { hydra_user_config disable_zeroing n "Disable zeroing of lvm volumes? (y/n)" hydra_user_config hostname $HOSTNAME "Hostname" hydra_user_config domain example.org "Domain" - hydra_user_config arch amd64 "System arch" + hydra_user_config arch $base_arch "System arch" hydra_user_config version wheezy "Distro version" hydra_user_config vg vg "Install vg" hydra_user_config grub y "Setup GRUB? (y/n)" -- cgit v1.2.3