Skip to content

Commit

Permalink
Merge pull request #1 from kacerr/kacerr-patch-add-option-not-to-crea…
Browse files Browse the repository at this point in the history
…te-mountdir

Add option to not to create mountdir into mount.pp
  • Loading branch information
kacerr committed Oct 16, 2015
2 parents 23b1055 + 2686609 commit 008b1f2
Showing 1 changed file with 16 additions and 13 deletions.
29 changes: 16 additions & 13 deletions manifests/mount.pp
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
$shorewall = false,
$owner = '', # mount owner
$group = '', # mount group
$manage_mount_directory = true # enable/disable creation of directory to mount into
) {
include gluster::params

Expand Down Expand Up @@ -138,19 +139,21 @@
}

# make an empty directory for the mount point
file { "${long_name}": # ensure a trailing slash
ensure => directory, # make sure this is a directory
recurse => false, # don't recurse into directory
purge => false, # don't purge unmanaged files
force => false, # don't purge subdirs and links
alias => "${short_name}", # don't allow duplicates name's
owner => "${owner}" ? { # make sure owner is undef if not specified
'' => undef,
default => $owner,
},
group => "${group}" ? { # make sure group is undef if not specified
'' => undef,
default => $group,
if $manage_mount_directory {
file { "${long_name}": # ensure a trailing slash
ensure => directory, # make sure this is a directory
recurse => false, # don't recurse into directory
purge => false, # don't purge unmanaged files
force => false, # don't purge subdirs and links
alias => "${short_name}", # don't allow duplicates name's
owner => "${owner}" ? { # make sure owner is undef if not specified
'' => undef,
default => $owner,
},
group => "${group}" ? { # make sure group is undef if not specified
'' => undef,
default => $group,
}
}
}

Expand Down

0 comments on commit 008b1f2

Please sign in to comment.