Defined Type: ferm::client

Defined in:
modules/ferm/manifests/client.pp

Overview

Define ferm::client

Uses ferm def &CLIENT or &R_CLIENT to allow outbound connections on the specific protocol and destination port.

If $drange is not provided, all destination addresses will be allowed. otherwise only traffic towards $drange will be allowed.

Parameters:

  • proto (Any)
  • port (Any)
  • ensure (Any) (defaults to: present)
  • desc (Any) (defaults to: '')
  • prio (Any) (defaults to: '10')
  • drange (Any) (defaults to: undef)
  • notrack (Any) (defaults to: false)


8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# File 'modules/ferm/manifests/client.pp', line 8

define ferm::client(
    $proto,
    $port,
    $ensure  = present,
    $desc    = '',
    $prio    = '10',
    $drange  = undef,
    $notrack = false,
) {
    @file { "/etc/ferm/conf.d/${prio}_${name}_client":
        ensure  => $ensure,
        owner   => 'root',
        group   => 'root',
        mode    => '0400',
        content => template('ferm/client.erb'),
        require => File['/etc/ferm/conf.d'],
        notify  => Service['ferm'],
        tag     => 'ferm',
    }
}