[pve-devel] [PATCH container 1/1] migrate: remove deprecated force parameter

Fabian Ebner f.ebner at proxmox.com
Fri Jun 4 15:49:27 CEST 2021


Signed-off-by: Fabian Ebner <f.ebner at proxmox.com>
---
 src/PVE/API2/LXC.pm    | 6 ------
 src/PVE/LXC/Migrate.pm | 8 +-------
 2 files changed, 1 insertion(+), 13 deletions(-)

diff --git a/src/PVE/API2/LXC.pm b/src/PVE/API2/LXC.pm
index 4965f5d..936debb 100644
--- a/src/PVE/API2/LXC.pm
+++ b/src/PVE/API2/LXC.pm
@@ -1076,12 +1076,6 @@ __PACKAGE__->register_method({
 		optional => 1,
 		default => 180,
 	    },
-	    force => {
-		type => 'boolean',
-		description => "Force migration despite local bind / device" .
-		    " mounts. NOTE: deprecated, use 'shared' property of mount point instead.",
-		optional => 1,
-	    },
 	    bwlimit => {
 		description => "Override I/O bandwidth limit (in KiB/s).",
 		optional => 1,
diff --git a/src/PVE/LXC/Migrate.pm b/src/PVE/LXC/Migrate.pm
index cb1ea7a..b5917e9 100644
--- a/src/PVE/LXC/Migrate.pm
+++ b/src/PVE/LXC/Migrate.pm
@@ -44,20 +44,14 @@ sub prepare {
     }
     $self->{was_running} = $running;
 
-    my $force = $self->{opts}->{force} // 0;
-
     PVE::LXC::Config->foreach_volume($conf, sub {
 	my ($ms, $mountpoint) = @_;
 
 	my $volid = $mountpoint->{volume};
 	my $type = $mountpoint->{type};
 
-	# skip dev/bind mps when forced / shared
+	# skip dev/bind mps when shared
 	if ($type ne 'volume') {
-	    if ($force) {
-		warn "-force is deprecated, please use the 'shared' property on individual non-volume mount points instead!\n";
-		return;
-	    }
 	    if ($mountpoint->{shared}) {
 		return;
 	    } else {
-- 
2.30.2






More information about the pve-devel mailing list