Puppet Class: nftables::rules::samba

Defined in:
manifests/rules/samba.pp

Summary

manage Samba, the suite to allow Windows file sharing on Linux resources.

Overview

Parameters:

  • ctdb (Boolean) (defaults to: false)

    Enable ctdb-driven clustered Samba setups

  • action (Enum['accept', 'drop']) (defaults to: 'accept')

    if the traffic should be allowed or dropped



6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# File 'manifests/rules/samba.pp', line 6

class nftables::rules::samba (
  Boolean $ctdb = false,
  Enum['accept', 'drop'] $action = 'accept',
) {
  nftables::rule {
    'default_in-netbios_tcp':
      content => "tcp dport {139,445} ${action}",
  }

  nftables::rule {
    'default_in-netbios_udp':
      content => "udp dport {137,138} ${action}",
  }

  if $ctdb {
    nftables::rule {
      'default_in-ctdb':
        content => "tcp dport 4379 ${action}",
    }
  }
}