diff options
author | Christian Breunig <christian@breunig.cc> | 2024-09-30 17:23:22 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-09-30 17:23:22 +0200 |
commit | 69517137cf56516f270e8db46c9fcfc61a96c74a (patch) | |
tree | 0279c95341f505c1b271fa40c384367b30320133 /data/templates | |
parent | 679c67e53cda6189e8add0d39988304935162071 (diff) | |
parent | 1621d841aced7bdc295a572a412613be1ec404c0 (diff) | |
download | vyos-1x-69517137cf56516f270e8db46c9fcfc61a96c74a.tar.gz vyos-1x-69517137cf56516f270e8db46c9fcfc61a96c74a.zip |
Merge pull request #4114 from vyos/mergify/bp/sagitta/pr-4061
syslog: T5367: add format option to include timezone in message (backport #4061)
Diffstat (limited to 'data/templates')
-rw-r--r-- | data/templates/rsyslog/rsyslog.conf.j2 | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/data/templates/rsyslog/rsyslog.conf.j2 b/data/templates/rsyslog/rsyslog.conf.j2 index 0141812ac..7fd592d1f 100644 --- a/data/templates/rsyslog/rsyslog.conf.j2 +++ b/data/templates/rsyslog/rsyslog.conf.j2 @@ -58,12 +58,10 @@ $outchannel {{ file_name }},/var/log/user/{{ file_name }},{{ file_options.archiv {% endif %} {% if host_options.protocol is vyos_defined('tcp') %} {% if host_options.format.octet_counted is vyos_defined %} -{{ tmp | join(';') }} @@(o){{ host_name | bracketize_ipv6 }}:{{ host_options.port }};RSYSLOG_SyslogProtocol23Format -{% else %} -{{ tmp | join(';') }} @@{{ host_name | bracketize_ipv6 }}:{{ host_options.port }} +{{ tmp | join(';') }} @@{{ '(o)' if host_options.format.octet_counted is vyos_defined }}{{ host_name | bracketize_ipv6 }}:{{ host_options.port }}{{ ';RSYSLOG_SyslogProtocol23Format' if host_options.format.include_timezone is vyos_defined }} {% endif %} {% else %} -{{ tmp | join(';') }} @{{ host_name | bracketize_ipv6 }}:{{ host_options.port }}{{ ';RSYSLOG_SyslogProtocol23Format' if host_options.format.octet_counted is vyos_defined }} +{{ tmp | join(';') }} @{{ host_name | bracketize_ipv6 }}:{{ host_options.port }}{{ ';RSYSLOG_SyslogProtocol23Format' if host_options.format.include_timezone is vyos_defined }} {% endif %} {% endfor %} {% endif %} |