guests/windows: fix network configuring
This commit is contained in:
parent
d600e83e6d
commit
a908b191b0
|
@ -63,7 +63,7 @@ module VagrantPlugins
|
||||||
# https://github.com/WinRb/vagrant-windows/issues/63
|
# https://github.com/WinRb/vagrant-windows/issues/63
|
||||||
def set_all_networks_to_work
|
def set_all_networks_to_work
|
||||||
@logger.info("Setting all networks to 'Work Network'")
|
@logger.info("Setting all networks to 'Work Network'")
|
||||||
command = File.read(File.expand_path("../scripts/set_work_network.ps1"))
|
command = File.read(File.expand_path("../scripts/set_work_network.ps1", __FILE__))
|
||||||
@winrmshell.powershell(command)
|
@winrmshell.powershell(command)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -106,7 +106,7 @@ module VagrantPlugins
|
||||||
#
|
#
|
||||||
# @return [Array]
|
# @return [Array]
|
||||||
def network_adapters_v3_winrm
|
def network_adapters_v3_winrm
|
||||||
command = File.read(File.expand_path("../scripts/winrs_v3_get_adapters.ps1"))
|
command = File.read(File.expand_path("../scripts/winrs_v3_get_adapters.ps1", __FILE__))
|
||||||
output = ""
|
output = ""
|
||||||
@winrmshell.powershell(command) do |type, line|
|
@winrmshell.powershell(command) do |type, line|
|
||||||
output = output + "#{line}" if type == :stdout && !line.nil?
|
output = output + "#{line}" if type == :stdout && !line.nil?
|
||||||
|
|
Loading…
Reference in New Issue