Commit ca53e003 authored by Nathan Ward's avatar Nathan Ward
Browse files

Fixes for puppet code validation errors

parent a4f645af
......@@ -11,6 +11,11 @@ define freeradius::blank {
group => $fr_group,
require => [File[$fr_basepath], Package[$fr_package], Group[$fr_group]],
notify => Service[$fr_service],
content => '# This file is intentionally left blank to reduce complexity. Blanking it but leaving it present is safer than deleting it, since the package manager will replace some files if they are deleted, leading to unexpected behaviour!',
content => @(BLANK/L),
# This file is intentionally left blank to reduce complexity. \
Blanking it but leaving it present is safer than deleting it, \
since the package manager will replace some files if they are \
deleted, leading to unexpected behaviour!
|-BLANK
}
}
......@@ -7,7 +7,21 @@ define freeradius::client (
Optional[Enum['*', 'udp', 'tcp']] $proto = '*',
Freeradius::Boolean $require_message_authenticator = 'no',
Optional[String] $virtual_server = undef,
Optional[Enum['cisco', 'computone', 'livingston', 'juniper', 'max40xx', 'multitech', 'netserver', 'pathras', 'patton', 'portslave', 'tc', 'usrhiper', 'other']] $nastype = undef,
Optional[Enum[
'cisco',
'computone',
'livingston',
'juniper',
'max40xx',
'multitech',
'netserver',
'pathras',
'patton',
'portslave',
'tc',
'usrhiper',
'other',
]] $nastype = undef,
Optional[String] $login = undef,
Optional[String] $password = undef,
Optional[String] $coa_server = undef,
......
# Configure a home_server for proxy config
define freeradius::home_server (
Enum['udp', 'tcp'] $proto = 'udp',
String $secret,
Enum['udp', 'tcp'] $proto = 'udp',
Enum['none', 'status-server', 'request'] $status_check = 'none',
Enum['auth', 'acct', 'auth+acct', 'coa'] $type = 'auth',
Optional[Integer] $check_interval = undef,
......
......@@ -32,7 +32,11 @@ class freeradius (
"log_destination value (${log_destination}) is not a valid value")
if $control_socket == true {
warning('Use of the control_socket parameter in the freeradius class is deprecated. Please use the freeradius::control_socket class instead.')
warning(@(WARN/L)
Use of the control_socket parameter in the freeradius class is deprecated. \
Please use the freeradius::control_socket class instead.
|-WARN
)
}
# Always restart the service after every module operation
......@@ -324,12 +328,13 @@ class freeradius (
# We don't want to create the radiusd user, just add it to the
# wbpriv group if the user needs winbind support. We depend on
# the FreeRADIUS package to be sure that the user has been created
$fr_user_group = $winbind_support ? {
true => $freeradius::fr_wbpriv_user,
default => undef,
}
user { $freeradius::fr_user:
ensure => present,
groups => $winbind_support ? {
true => $freeradius::fr_wbpriv_user,
default => undef,
},
groups => $fr_user_group,
require => Package[$freeradius::fr_package],
}
......@@ -344,7 +349,7 @@ class freeradius (
# Syslog rules
if $syslog == true {
rsyslog::snippet { '12-radiusd-log':
content => "if \$programname == \'radiusd\' then ${freeradius::fr_logpath}/radius.log\n\&\~",
content => "if \$programname == \'radiusd\' then ${freeradius::fr_logpath}/radius.log\n\\&\\~",
}
}
......
......@@ -39,6 +39,9 @@ class freeradius::params {
default => '2',
}
}
default: {
fail("OS ${::operatingsystem} is not supported")
}
}
# Use the FR version fact if defined, otherwise use our best estimate from above
......
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