On 01/31/2012 04:46 PM, Christopher Wood wrote:
> This sounds like you want a define rather than a class.

Possibly, but not yet determined ;-)

> gross, horrible

How so? It's not a bad example. If you dislike the data redundancy, I
suggest:

define mail::mount($mount_base="/mail") {

  include nfs::client

  $mountpoint = "$mount_base/$name"

  file { $mountpoint: ensure => directory, }

  mount { $mountpoint:
    ensure => mounted,
    device => "filer:/$name",
    options =>
'tcp,rsize=32768,wsize=32768,hard,nointr,timeo=600,retrans=2,mountvers=3,nfsvers=3',
    fstype => 'nfs',
    atboot => true,
    require => [File[$mountpoint], Class['nfs::client']],
  }

}

and then

mail::mount { [ 'mail0', 'mail1' ]: }

IMHO, there's not much more that desperately needs changing in your code.

Cheers,
Felix

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to