summaryrefslogtreecommitdiff
path: root/puppet/modules/shorewall/manifests/extension_script.pp
blob: 569fcbf8b24ca4c37fa1845e0c49e13376661115 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
# See http://shorewall.net/shorewall_extension_scripts.htm
define shorewall::extension_script($script = '') {
    case $name {
        'init', 'initdone', 'start', 'started', 'stop', 'stopped', 'clear', 'refresh', 'continue', 'maclog': {
          file { "/etc/shorewall/puppet/${name}":
            content => "${script}\n",
            notify => Service[shorewall];
          }
        }
        '', default: {
          err("${name}: unknown shorewall extension script")
        }
    }
}