Commit 0bd952b7 authored by Jonathan's avatar Jonathan Committed by GitHub
Browse files

Merge pull request #47 from amateo/feature/syslog

Adds option to configure destination of logs
parents 2b9bc773 0bc89073
...@@ -107,6 +107,9 @@ Install wpa_supplicant utility. Default: `false` ...@@ -107,6 +107,9 @@ Install wpa_supplicant utility. Default: `false`
##### `winbind_support` ##### `winbind_support`
Add the radius user to the winbind privileged group. You must install winbind separately. Default: `false`. Add the radius user to the winbind privileged group. You must install winbind separately. Default: `false`.
##### `log_destination`
Configure destination of log messages. Valid values are `files`, `syslog`, `stdout` and `stderr`. Default: `files`.
##### `syslog` ##### `syslog`
Add a syslog rule (using the `saz/rsyslog` module). Default: `false`. Add a syslog rule (using the `saz/rsyslog` module). Default: `false`.
......
...@@ -10,6 +10,7 @@ class freeradius ( ...@@ -10,6 +10,7 @@ class freeradius (
$krb5_support = false, $krb5_support = false,
$wpa_supplicant = false, $wpa_supplicant = false,
$winbind_support = false, $winbind_support = false,
$log_destination = 'files',
$syslog = false, $syslog = false,
$log_auth = 'no', $log_auth = 'no',
$preserve_mods = true, $preserve_mods = true,
...@@ -17,6 +18,9 @@ class freeradius ( ...@@ -17,6 +18,9 @@ class freeradius (
validate_re($freeradius::fr_version, '^3', 'This module is only compatible with FreeRADIUS 3') validate_re($freeradius::fr_version, '^3', 'This module is only compatible with FreeRADIUS 3')
validate_re($log_destination, '^(files|syslog|stdout|stderr)$',
"log_destination value (${log_destination}) is not a valid value")
if $control_socket == true { 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('Use of the control_socket parameter in the freeradius class is deprecated. Please use the freeradius::control_socket class instead.')
} }
......
...@@ -243,7 +243,7 @@ log { ...@@ -243,7 +243,7 @@ log {
# The command-line option "-X" over-rides this option, and forces # The command-line option "-X" over-rides this option, and forces
# logging to go to stdout. # logging to go to stdout.
# #
destination = files destination = <%= @log_destination %>
# #
# Highlight important messages sent to stderr and stdout. # Highlight important messages sent to stderr and stdout.
......
Supports Markdown
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