Skip to content

Instantly share code, notes, and snippets.

execute "mkfs" do
command "mkfs -t #{options[:fstype]} #{device}"
not_if do
# wait for the device
loop do
if File.blockdev?(device)
Chef::Log.info("device #{device} ready")
break
else
set_unless[:cookbook_support][:poll][:dir] = "/data/chef/chef_polls"