mirror of
https://github.com/netbirdio/plugins.git
synced 2026-05-22 18:44:07 -07:00
(tinc) fix syslog, every tinc network uses it's own facility
This commit is contained in:
@@ -44,9 +44,16 @@ function if_tinc_syslog()
|
||||
$logfacilities = array();
|
||||
|
||||
$logfacilities['tinc'] = array(
|
||||
'facility' => array('tinc'),
|
||||
'facility' => array(),
|
||||
'remote' => 'vpn',
|
||||
);
|
||||
$mdl = new \OPNsense\Tinc\Tinc();
|
||||
|
||||
foreach ($mdl->networks->network->__items as $network) {
|
||||
if ($network->enabled == '1') {
|
||||
$logfacilities['tinc']['facility'][] = 'tinc.'.$network->name;
|
||||
}
|
||||
}
|
||||
|
||||
return $logfacilities;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user