Puppet Class: nfs::server::debian

Defined in:
manifests/server/debian.pp

Overview

Debian specifix stuff

Parameters:

  • nfs_v4 (Any) (defaults to: false)
  • nfs_v4_idmap_domain (Any) (defaults to: undef)
  • mountd_port (Any) (defaults to: undef)
  • mountd_threads (Any) (defaults to: 8)
  • service_manage (Any) (defaults to: true)


2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# File 'manifests/server/debian.pp', line 2

class nfs::server::debian(
  $nfs_v4              = false,
  $nfs_v4_idmap_domain = undef,
  $mountd_port         = undef,
  $mountd_threads      = 8,
  $service_manage      = true,
) {

  if !defined(Class['nfs::client::debian']) {
    class{ 'nfs::client::debian':
      nfs_v4              => $nfs_v4,
      nfs_v4_idmap_domain => $nfs_v4_idmap_domain,
    }
  }

  if ($mountd_port != undef){
    file_line { 'rpc-mount-options':
      ensure  => present,
      path    => '/etc/default/nfs-kernel-server',
      line    => "RPCMOUNTDOPTS=\"--manage-gids --port ${mountd_port} --num-threads ${mountd_threads}\"",
      match   => '^#?RPCMOUNTDOPTS',
      require => Package['nfs-kernel-server'];
    }

    if $service_manage {
      File_line['rpc-mount-options'] ~> Service['nfs-kernel-server']
    }
  }

  include nfs::server::debian::install, nfs::server::debian::service
}