Fix path variable name. Return process result.
This commit is contained in:
parent
a5582eb1c8
commit
98c6903e9c
|
@ -10,14 +10,15 @@ module VagrantPlugins
|
||||||
def self.set_ssh_key_permissions(env, key_path)
|
def self.set_ssh_key_permissions(env, key_path)
|
||||||
script_path = Host.scripts_path.join("set_ssh_key_permissions.ps1")
|
script_path = Host.scripts_path.join("set_ssh_key_permissions.ps1")
|
||||||
result = Vagrant::Util::PowerShell.execute(
|
result = Vagrant::Util::PowerShell.execute(
|
||||||
script_path.to_s, path.to_s,
|
script_path.to_s, key_path.to_s,
|
||||||
module_path: Host.module_path.to_s
|
module_path: Host.modules_path.to_s
|
||||||
)
|
)
|
||||||
if result.exit_code != 0
|
if result.exit_code != 0
|
||||||
raise Vagrant::Errors::PowerShellError,
|
raise Vagrant::Errors::PowerShellError,
|
||||||
script: script_path,
|
script: script_path,
|
||||||
stderr: result.stderr
|
stderr: result.stderr
|
||||||
end
|
end
|
||||||
|
result
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue