diff options
author | Steven Murawski <steven.murawski@gmail.com> | 2015-07-20 15:57:26 -0500 |
---|---|---|
committer | Steven Murawski <steven.murawski@gmail.com> | 2015-07-20 15:57:26 -0500 |
commit | 65250670550cc8dc0cdbfd05826665b2933a1d5f (patch) | |
tree | 46fe88ea907768e4c8c0006028dbd30911c10a9a | |
parent | 079b49892cd49a7341fd68bed0a599db18d7809b (diff) | |
parent | 704774b3d05273b9fdfbc45cf464a6f1f00c4d10 (diff) | |
download | chef-65250670550cc8dc0cdbfd05826665b2933a1d5f.tar.gz |
Merge pull request #3683 from jimmymccrory/windows_rebooter_minutes
Correct Windows reboot command to delay in minutes
-rw-r--r-- | lib/chef/platform/rebooter.rb | 2 | ||||
-rw-r--r-- | spec/functional/rebooter_spec.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/chef/platform/rebooter.rb b/lib/chef/platform/rebooter.rb index b46f0e394c..b78ac38f0c 100644 --- a/lib/chef/platform/rebooter.rb +++ b/lib/chef/platform/rebooter.rb @@ -32,7 +32,7 @@ class Chef cmd = if Chef::Platform.windows? # should this do /f as well? do we then need a minimum delay to let apps quit? - "shutdown /r /t #{reboot_info[:delay_mins]} /c \"#{reboot_info[:reason]}\"" + "shutdown /r /t #{reboot_info[:delay_mins]*60} /c \"#{reboot_info[:reason]}\"" else # probably Linux-only. "shutdown -r +#{reboot_info[:delay_mins]} \"#{reboot_info[:reason]}\"" diff --git a/spec/functional/rebooter_spec.rb b/spec/functional/rebooter_spec.rb index 485e98f247..a0e2665de5 100644 --- a/spec/functional/rebooter_spec.rb +++ b/spec/functional/rebooter_spec.rb @@ -43,7 +43,7 @@ describe Chef::Platform::Rebooter do let(:expected) do { - :windows => 'shutdown /r /t 5 /c "rebooter spec test"', + :windows => 'shutdown /r /t 300 /c "rebooter spec test"', :linux => 'shutdown -r +5 "rebooter spec test"' } end |