summaryrefslogtreecommitdiffstats
path: root/lib/puppet
diff options
context:
space:
mode:
Diffstat (limited to 'lib/puppet')
-rwxr-xr-xlib/puppet/type/mount.rb16
1 files changed, 14 insertions, 2 deletions
diff --git a/lib/puppet/type/mount.rb b/lib/puppet/type/mount.rb
index b2686a20e..2a393391d 100755
--- a/lib/puppet/type/mount.rb
+++ b/lib/puppet/type/mount.rb
@@ -49,11 +49,23 @@ module Puppet
end
syncothers()
- provider.mount
+ # The fs can be already mounted if it was absent but mounted
+ unless provider.mounted?
+ provider.mount
+ end
end
def retrieve
- return provider.mounted? ? :mounted : super()
+ # We need to special case :mounted; if we're absent, we still
+ # want
+ curval = super()
+ if curval == :absent
+ return curval
+ elsif provider.mounted?
+ return :mounted
+ else
+ return curval
+ end
end
def syncothers