chef
https://github.com/opscode/chef
Ruby
A systems integration framework, built to bring the benefits of configuration management to your entire infrastructure.
Chef::RunContext#request_reboot
there are options for how to handle multiple calls to these functions: 1. first call always wins (never change reboot_info once set). 2. last call always wins (happily change reboot_info whenever). 3. raise an exception on the first conflict. 4. disable reboot after this run if anyone ever calls :cancel. 5. raise an exception on any second call. 6. ?
Edit
git clone [email protected]:opscode/chef.git
cd chef
open lib/chef/run_context.rb
Contribute
# Make a new branchgit checkout -b -your-name--update-docs-Chef--RunContext-request_reboot-for-pr
# Commit to gitgit add lib/chef/run_context.rbgit commit -m "better docs for Chef::RunContext#request_reboot"
# Open pull requestgem install hub # on a mac you can `brew install hub`
hub fork
git push <your name> -your-name--update-docs-Chef--RunContext-request_reboot-for-pr
hub pull-request
# Celebrate!