install_production: improve the partition check (#1692)

Signed-off-by: szaimen <szaimen@e.mail.de>

Co-authored-by: Daniel Hansson <github@hanssonit.se>
This commit is contained in:
szaimen 2020-11-23 16:45:45 +01:00 committed by GitHub
parent c0a26c46bd
commit bb06b84752
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -46,20 +46,10 @@ fi
is_process_running apt
is_process_running dpkg
# Test if snapshot already exists
if does_snapshot_exist "NcVM-installation"
then
msg_box "Unable to continue because a logical volume already exists.
To run this script again, please remove the volume by running:
'sudo lvremove /dev/ubuntu-vg/NcVM-installation'"
exit 1
fi
# Create a placeholder volume before modifying anything
if [ -z "$PROVISIONING" ]
then
if yesno_box_no "Do you want to use LVM snapshots to be able to restore your root partition during upgrades and such?
if ! does_snapshot_exist "NcVM-installation" && yesno_box_no "Do you want to use LVM snapshots to be able to restore your root partition during upgrades and such?
Please note: this feature will not be used by this script but by other scripts later on.
For now we will only create a placeholder volume that will be used to let some space for snapshot volumes."
then