treewide: sysupgrade: pass "save_partitions" option to the "sysupgrade" method
This explicitly lets stage2 know if partitions should be preserved. No more "touch /tmp/sysupgrade.always.overwrite.bootdisk.partmap" hack. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
This commit is contained in:
@@ -351,12 +351,6 @@ if [ $TEST -eq 1 ]; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [ $SAVE_PARTITIONS -eq 0 ]; then
|
||||
touch /tmp/sysupgrade.always.overwrite.bootdisk.partmap
|
||||
else
|
||||
rm -f /tmp/sysupgrade.always.overwrite.bootdisk.partmap
|
||||
fi
|
||||
|
||||
install_bin /sbin/upgraded
|
||||
v "Commencing upgrade. Closing all shell sessions."
|
||||
|
||||
@@ -371,7 +365,8 @@ else
|
||||
\"path\": $(json_string "$IMAGE"),
|
||||
\"command\": $(json_string "$COMMAND"),
|
||||
\"options\": {
|
||||
\"save_config\": $SAVE_CONFIG
|
||||
\"save_config\": $SAVE_CONFIG,
|
||||
\"save_partitions\": $SAVE_PARTITIONS
|
||||
}
|
||||
}"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user