summaryrefslogtreecommitdiff
path: root/lib/chef
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef')
-rw-r--r--lib/chef/provider/mount.rb14
1 files changed, 9 insertions, 5 deletions
diff --git a/lib/chef/provider/mount.rb b/lib/chef/provider/mount.rb
index 50f3228266..019fab718f 100644
--- a/lib/chef/provider/mount.rb
+++ b/lib/chef/provider/mount.rb
@@ -65,11 +65,15 @@ class Chef
Chef::Log.info("#{@new_resource} remounted")
end
else
- umount_fs
- Chef::Log.info("#{@new_resource} unmounted")
- sleep 1
- mount_fs
- Chef::Log.info("#{@new_resource} mounted")
+ converge_by("unmount #{@current_resource.device}") do
+ umount_fs
+ Chef::Log.info("#{@new_resource} unmounted")
+ end
+ sleep 3
+ converge_by("mount #{@current_resource.device}") do
+ mount_fs
+ Chef::Log.info("#{@new_resource} mounted")
+ end
end
else
Chef::Log.debug("#{@new_resource} not mounted, nothing to remount")