hydra_user_config domain example.com "Domain"
hydra_user_config arch amd64 "System arch"
hydra_user_config version wheezy "Distro version"
- hydra_user_config vg vg "Temporary install vg"
+ hydra_user_config vg vg "Install vg"
hydra_user_config grub y "Setup GRUB? (y/n)"
hydra_user_config mirror http://http.debian.net/debian/ "Debian mirror"
}
# Warning.
if [ "$interactive" == "y" ]; then
- echo "WARNING: about to partition $device!"
+ echo "WARNING: about to create partitions on $device!"
+ echo "WARNING: make sure you have backups of the important data from this device!"
echo "Press ENTER to continue, Ctrl-C to abort."
read answer
fi
if [ "$encrypt" == "y" ]; then
cat > /tmp/debootstrap/etc/crypttab <<-EOF
-root /dev/mapper/vg-root none luks,cipher=aes-cbc-essiv:sha256
+root /dev/mapper/$vg-root none luks,cipher=aes-cbc-essiv:sha256
EOF
fi
if [ "$home_size" != "0" ] && [ "$encrypt" == "y" ]; then
cat >> /tmp/debootstrap/etc/crypttab <<-EOF
-home /dev/mapper/vg-home none luks,cipher=aes-cbc-essiv:sha256
+home /dev/mapper/$vg-home none luks,cipher=aes-cbc-essiv:sha256
EOF
fi
if [ "$var_size" != "0" ] && [ "$encrypt" == "y" ]; then
cat >> /tmp/debootstrap/etc/crypttab <<-EOF
-var /dev/mapper/vg-var none luks,cipher=aes-cbc-essiv:sha256
+var /dev/mapper/$vg-var none luks,cipher=aes-cbc-essiv:sha256
EOF
fi
EOF
else
cat >> /tmp/debootstrap/etc/fstab <<-EOF
-/dev/mapper/vg-root / ext4 defaults,errors=remount-ro 0 1
+/dev/mapper/$vg-root / ext4 defaults,errors=remount-ro 0 1
EOF
fi
EOF
else
cat >> /tmp/debootstrap/etc/fstab <<-EOF
-/dev/mapper/vg-home /home ext4 defaults,errors=remount-ro 0 2
+/dev/mapper/$vg-home /home ext4 defaults,errors=remount-ro 0 2
EOF
fi
fi
EOF
else
cat >> /tmp/debootstrap/etc/fstab <<-EOF
-/dev/mapper/vg-var /var ext4 defaults,errors=remount-ro 0 2
+/dev/mapper/$vg-var /var ext4 defaults,errors=remount-ro 0 2
EOF
fi
fi
- Create an user account with sudo privileges.
- Network setup.
+ - Rename volume group $vg if needed, updating fstab and crypttab accordingly.
See http://padrao.sarava.org/install for more information.
EOF