summaryrefslogtreecommitdiff
path: root/puppet/modules/site_shorewall/manifests/sshd.pp
blob: a8e09e422ade0b74ab170aee9f1feaeed41316b8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
class site_shorewall::sshd {

  $ssh_config     = hiera('ssh')
  $ssh_port       = $ssh_config['port']

  include shorewall

  # define macro for incoming sshd
  file { '/etc/shorewall/macro.leap_sshd':
    content => "PARAM   -       -       tcp    $ssh_port",
    notify  => Service['shorewall'],
    require => Package['shorewall']
  }


  shorewall::rule {
      # outside to server
      'net2fw-ssh':
        source      => 'net',
        destination => '$FW',
        action      => 'leap_sshd(ACCEPT)',
        order       => 200;
  }
}