35 lines
942 B
Django/Jinja
35 lines
942 B
Django/Jinja
#
|
|
# The order counts
|
|
#
|
|
{% if rsyslog_enable_remote_udp == 'enabled' %}
|
|
# Provides UDP syslog reception
|
|
module(load="imudp") # needs to be done just once
|
|
# input(type="imudp" port="{{ rsyslog_udp_port }}")
|
|
{% endif %}
|
|
|
|
{% if rsyslog_enable_remote_tcp == 'enabled' %}
|
|
# Provides TCP syslog reception
|
|
module(load="imtcp") # needs to be done just once
|
|
# input(type="imtcp" port="{{ rsyslog_tcp_port }}")
|
|
{% endif %}
|
|
|
|
# log every host in its own directory
|
|
$template RemoteHost,"{{ rsyslog_remote_path }}/%HOSTNAME%/syslog.log"
|
|
$RuleSet remote
|
|
*.* ?RemoteHost
|
|
|
|
{% if rsyslog_enable_remote_udp == 'enabled' %}
|
|
# bind the ruleset to the udp listener
|
|
$InputUDPServerBindRuleset remote
|
|
# and activate it:
|
|
$UDPServerRun {{ rsyslog_udp_port }}
|
|
{% endif %}
|
|
|
|
{% if rsyslog_enable_remote_tcp == 'enabled' %}
|
|
# bind the ruleset to the tcp listener
|
|
$InputTCPServerBindRuleset remote
|
|
# and activate it:
|
|
$InputTCPServerRun {{ rsyslog_tcp_port }}
|
|
{% endif %}
|
|
|