blob: d3785a15d603555b421da8face0eb981cac4b23a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
class firewall::redirect::ssh($destinationport) {
# When the box is in an internal network and we want to provide
# and external access through a shared real IP, we have to
# redirect requests coming from another port to port 22.
$ip = hiera('firewall::external_ip', $::ipaddress)
shorewall::rule { "ssh-redirect-1":
action => 'DNAT',
source => 'net',
destination => "fw:$ip:22",
proto => 'tcp',
destinationport => $destinationport,
ratelimit => '-',
order => $destinationport,
}
}
|