From f42ea29b18c380c3eeed9783698b1830cf65ab66 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Fabian=20Gr=C3=BCnbichler?= Date: Mon, 11 Nov 2019 11:28:28 +0100 Subject: [PATCH] use PVE::SSHInfo MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Fabian Grünbichler --- PVE/API2/Qemu.pm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index f9e433b..0d81b53 100644 --- a/PVE/API2/Qemu.pm +++ b/PVE/API2/Qemu.pm @@ -29,6 +29,7 @@ use PVE::API2::Firewall::VM; use PVE::API2::Qemu::Agent; use PVE::VZDump::Plugin; use PVE::DataCenterConfig; +use PVE::SSHInfo; BEGIN { if (!$ENV{PVE_GENERATING_DOCS}) { @@ -1554,9 +1555,9 @@ __PACKAGE__->register_method({ if ($node ne 'localhost' && $node ne PVE::INotify::nodename()) { (undef, $family) = PVE::Cluster::remote_node_ip($node); - my $sshinfo = PVE::Cluster::get_ssh_info($node); + my $sshinfo = PVE::SSHInfo::get_ssh_info($node); # NOTE: kvm VNC traffic is already TLS encrypted or is known unsecure - $remcmd = PVE::Cluster::ssh_info_to_command($sshinfo, $use_serial ? '-t' : '-T'); + $remcmd = PVE::SSHInfo::ssh_info_to_command($sshinfo, $use_serial ? '-t' : '-T'); } else { $family = PVE::Tools::get_host_address_family($node); } @@ -1694,8 +1695,8 @@ __PACKAGE__->register_method({ if ($node ne 'localhost' && $node ne PVE::INotify::nodename()) { (undef, $family) = PVE::Cluster::remote_node_ip($node); - my $sshinfo = PVE::Cluster::get_ssh_info($node); - $remcmd = PVE::Cluster::ssh_info_to_command($sshinfo, '-t'); + my $sshinfo = PVE::SSHInfo::get_ssh_info($node); + $remcmd = PVE::SSHInfo::ssh_info_to_command($sshinfo, '-t'); push @$remcmd, '--'; } else { $family = PVE::Tools::get_host_address_family($node); -- 2.39.2