summaryrefslogtreecommitdiff
path: root/puppet/modules/site_shorewall/manifests/couchdb/dnat.pp
blob: f1bc9acfe19291ba8270885f19fcea9ff70ffd4a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
define site_shorewall::couchdb::dnat (
  $source,
  $connect,
  $connect_port,
  $accept_port,
  $proto,
  $destinationport )
{


  shorewall::rule {
    "dnat_${name}_${destinationport}":
      action          => 'DNAT',
      source          => $source,
      destination     => "\$FW:127.0.0.1:${accept_port}",
      proto           => $proto,
      destinationport => $destinationport,
      originaldest    => $connect,
      order           => 200
  }
}