From 803719d3f6a5526f7ea47b62af317156916e1e07 Mon Sep 17 00:00:00 2001 From: Brian Pitts Date: Sat, 1 Nov 2014 18:54:37 -0500 Subject: [PATCH] Fix port forwarding ssh process cleanup The presence of quotes in the command to spawn caused ruby to run it via a shell instead of running it directly. This broke our code for killing the ssh processes when the VM is halted. Closes #265 --- lib/vagrant-libvirt/action/forward_ports.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/vagrant-libvirt/action/forward_ports.rb b/lib/vagrant-libvirt/action/forward_ports.rb index 5fa86f0..27d4419 100644 --- a/lib/vagrant-libvirt/action/forward_ports.rb +++ b/lib/vagrant-libvirt/action/forward_ports.rb @@ -83,7 +83,8 @@ module VagrantPlugins gateway_ports) ssh_info = machine.ssh_info params = %W( - "-L #{host_ip}:#{host_port}:#{guest_ip}:#{guest_port}" + -L + #{host_ip}:#{host_port}:#{guest_ip}:#{guest_port} -N #{ssh_info[:host]} ).join(' ')