Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setting ['installation_reboot_mode'] = 'immediate_reboot' should not stop Chef run #117

Closed
DamonStamper opened this issue Oct 11, 2017 · 1 comment

Comments

@DamonStamper
Copy link

DamonStamper commented Oct 11, 2017

Cookbook version

6.1.1

Chef-client version

12.19.36

Platform Details

Windows 2012R2 (Vagrant image ['opentable/win-2012r2-standard-amd64-nocm'][virtualbox, 1.0.0)] )

Scenario:

When using 'powershell::powershell5' to install a new version of powershell and setting the ['installation_reboot_mode'] attribute to 'immediate_reboot' the Chef run stops at system reboot even if there are further resources to evaluate.

Steps to Reproduce:

set ['installation_reboot_mode'] attribute to 'immediate_reboot'.

Expected Result:

Chef reboots the computer and continues with the rest of its evaluation.

Actual Result:

Chef reboots the computer and stops its evaluation thus requiring a second run.

Notes:

The sql_server cookbook's 'server' recipe allows a reboot mid-Chef run. That functionality should be also implemented in the powershell cookbook.

Applicable code in sql_server cookbook.

@iennae
Copy link

iennae commented Oct 12, 2017

The behavior is working as expected. The sql_server doesn't reboot mid-Chef run. It sends a notification to reboot that occurs at the end of a successful chef run.

https://docs.chef.io/resource_reboot.html (request_reboot explanation)

immediate_reboot is going to reboot the system immediately. If you are trying to replicate the sql_server functionality, try the delayed_reboot option.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants