Skip to content
Snippets Groups Projects
Commit cf663a63 authored by Angel L. Mateo's avatar Angel L. Mateo
Browse files

Add status_check parameter to freeradius::home_server

This way you can configure how the home_server is check if it
dead or alive
parent 2b9bc773
No related branches found
No related tags found
No related merge requests found
......@@ -348,6 +348,10 @@ The transport protocol. If unspecified, defaults to "udp", which is the traditio
RADIUS transport. It may also be "tcp", in which case TCP will be used to talk to
this home server. Default: `udp`
##### `status_check`
Type of check to see if the home_server is dead or alive. Valid values are `none`, `status-server`
and `request`. Default: `undef`.
#### `freeradius::home_server_pool`
......
......@@ -7,6 +7,7 @@ define freeradius::home_server (
$virtual_server = '',
$port = 1812,
$proto = 'udp',
$status_check = undef,
) {
$fr_basepath = $::freeradius::params::fr_basepath
......@@ -23,6 +24,12 @@ define freeradius::home_server (
fail('$port must be an integer')
}
if $status_check {
unless $status_check in ['none', 'status-server', 'request'] {
fail('$status_check must be one of none, status-server, request')
}
}
# Configure config fragment for this home server
concat::fragment { "homeserver-${name}":
target => "${fr_basepath}/proxy.conf",
......
......@@ -12,5 +12,8 @@ home_server <%= @name %> {
port = <%= @port %>
proto = <%= @proto %>
secret = <%= @secret %>
<%- if @status_check -%>
status_check = <%= @status_check %>
<%- end -%>
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment