Merge pull request #1945 from znz/fix/master/forwarded_port-guest_ip
pass guest_ip option from config to driver [GH-1121]
This commit is contained in:
commit
d3993bb631
|
@ -69,6 +69,7 @@ module VagrantPlugins
|
||||||
# Add the options to the ports array to send to the driver later
|
# Add the options to the ports array to send to the driver later
|
||||||
ports << {
|
ports << {
|
||||||
:adapter => fp.adapter,
|
:adapter => fp.adapter,
|
||||||
|
:guestip => fp.guest_ip,
|
||||||
:guestport => fp.guest_port,
|
:guestport => fp.guest_port,
|
||||||
:hostip => fp.host_ip,
|
:hostip => fp.host_ip,
|
||||||
:hostport => fp.host_port,
|
:hostport => fp.host_port,
|
||||||
|
|
|
@ -24,6 +24,11 @@ module VagrantPlugins
|
||||||
# @return [String]
|
# @return [String]
|
||||||
attr_reader :protocol
|
attr_reader :protocol
|
||||||
|
|
||||||
|
# The IP that the forwarded port will connect to on the guest machine.
|
||||||
|
#
|
||||||
|
# @return [String]
|
||||||
|
attr_reader :guest_ip
|
||||||
|
|
||||||
# The port on the guest to be exposed on the host.
|
# The port on the guest to be exposed on the host.
|
||||||
#
|
#
|
||||||
# @return [Integer]
|
# @return [Integer]
|
||||||
|
@ -48,6 +53,7 @@ module VagrantPlugins
|
||||||
@auto_correct = true
|
@auto_correct = true
|
||||||
@auto_correct = options[:auto_correct] if options.has_key?(:auto_correct)
|
@auto_correct = options[:auto_correct] if options.has_key?(:auto_correct)
|
||||||
@adapter = (options[:adapter] || 1).to_i
|
@adapter = (options[:adapter] || 1).to_i
|
||||||
|
@guest_ip = options[:guest_ip] || nil
|
||||||
@host_ip = options[:host_ip] || nil
|
@host_ip = options[:host_ip] || nil
|
||||||
@protocol = options[:protocol] || "tcp"
|
@protocol = options[:protocol] || "tcp"
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue