Page Menu
Home
Software Heritage
Search
Configure Global Search
Log In
Files
F8390974
syslog.pp
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Subscribers
None
syslog.pp
View Options
# == Class: icinga2::feature::syslog
#
# This module configures the Icinga2 feature syslog.
#
# === Parameters
#
# [*ensure*]
# Set to present enables the feature syslog, absent disables it. Defaults to present.
#
# [*severity*]
# You can choose the log severity between information, notice, warning or debug.
# Defaults to warning.
#
# === Authors
#
# Icinga Development Team <info@icinga.com>
#
class
icinga2
::
feature
::
syslog
(
$ensure
=
present
,
$severity
=
'warning'
,
)
{
$conf_dir
=
$::icinga2::params::conf_dir
# validation
validate_re
(
$ensure,
[
'^present$'
,
'^absent$'
],
"${ensure} isn't supported. Valid values are 'present' and 'absent'."
)
validate_re
(
$severity,
[
'^information$'
,
'^notice$'
,
'^warning$'
,
'^debug$'
])
# compose attributes
$attrs
=
{
severity
=>
$severity,
}
# create object
icinga2
::
object
{
'icinga2::object::SyslogLogger::syslog'
:
object_name
=>
'syslog'
,
object_type
=>
'SyslogLogger'
,
attrs
=>
$attrs,
target
=>
"${conf_dir}/features-available/syslog.conf"
,
order
=>
'10'
,
notify
=>
$ensure
?
{
'present'
=>
Class
[
'::icinga2::service'
],
default
=>
undef
,
},
}
# manage feature
icinga2
::
feature
{
'syslog'
:
ensure
=>
$ensure,
}
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Jun 4 2025, 6:37 PM (14 w, 3 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3300850
Attached To
rSPICI Icinga 2 Puppet Module
Event Timeline
Log In to Comment