From b1bc49c0f3c27f66a318069e6a8a4dacfae76323 Mon Sep 17 00:00:00 2001 From: Jason Yan Date: Fri, 25 Feb 2011 14:47:08 -0800 Subject: [PATCH] Fix issue with port forwarding not respecting protocol option. --- lib/vagrant/action/vm/forward_ports.rb | 1 + lib/vagrant/config/vm.rb | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/vagrant/action/vm/forward_ports.rb b/lib/vagrant/action/vm/forward_ports.rb index d5f38dced..fed25083e 100644 --- a/lib/vagrant/action/vm/forward_ports.rb +++ b/lib/vagrant/action/vm/forward_ports.rb @@ -125,6 +125,7 @@ module Vagrant port.name = name port.guestport = options[:guestport] port.hostport = options[:hostport] + port.protocol = options[:protocol] || :tcp @env["vm"].vm.network_adapters[options[:adapter]].nat_driver.forwarded_ports << port end end diff --git a/lib/vagrant/config/vm.rb b/lib/vagrant/config/vm.rb index 7a072e8d2..87859c572 100644 --- a/lib/vagrant/config/vm.rb +++ b/lib/vagrant/config/vm.rb @@ -35,7 +35,7 @@ module Vagrant options = { :guestport => guestport, :hostport => hostport, - :protocol => "TCP", + :protocol => :tcp, :adapter => 0, :auto => false }.merge(options || {})