Commit 0a2b45ba authored by Jonathan Gazeley's avatar Jonathan Gazeley
Browse files

Manage ensure present/absent of status server with purge, like all other sites

parent 6aa25967
......@@ -105,7 +105,8 @@ class { 'freeradius':
#### `freeradius::status_server`
The `freeradius::status_server` class installs support for the [status server](http://wiki.freeradius.org/config/Status).
The `freeradius::status_server` class enabled the [status server](http://wiki.freeradius.org/config/Status).
To remove the status server, do not include this class and the server will be removed.
##### `secret`
The shared secret for the status server. Required.
......@@ -116,9 +117,6 @@ The port to listen for status requests on. Default: `18121`
##### `listen`
The address to listen on. Defaults to listen on all addresses but you could set this to `$::ipaddress` or `127.0.0.1`. Default: `*`
##### `enable`
Whether to enable the status server. Default: `true`
```puppet
# Enable status server
class { 'freeradius::status_server':
......
......@@ -3,12 +3,8 @@ class freeradius::status_server (
$secret,
$port = '18121',
$listen = '*',
$enable = true,
) {
freeradius::site { 'status':
content => $enable ? {
true => template('freeradius/sites-enabled/status.erb'),
default => '# Status server disabled',
}
content => template('freeradius/sites-enabled/status.erb'),
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment