Commit 9f08c530ac32b83102f8d8d30873ec58cd2decdd
1 parent
a4d4defc
Changing rsyslog.conf file to server.conf file
Showing
2 changed files
with
11 additions
and
55 deletions
Show diff stats
cookbooks/rsyslog/templates/server/rsyslog.conf.erb
| @@ -1,55 +0,0 @@ | @@ -1,55 +0,0 @@ | ||
| 1 | -#### MODULES #### | ||
| 2 | - | ||
| 3 | -# The imjournal module bellow is now used as a message source instead of imuxsock. | ||
| 4 | -$ModLoad imuxsock # provides support for local system logging (e.g. via logger command) | ||
| 5 | -$ModLoad imjournal # provides access to the systemd journal | ||
| 6 | - | ||
| 7 | -# Provides TCP syslog reception | ||
| 8 | -$ModLoad imtcp | ||
| 9 | -$InputTCPServerRun 514 | ||
| 10 | - | ||
| 11 | -#### GLOBAL DIRECTIVES #### | ||
| 12 | - | ||
| 13 | -# Where to place auxiliary files | ||
| 14 | -$WorkDirectory /var/lib/rsyslog | ||
| 15 | - | ||
| 16 | -# Use default timestamp format | ||
| 17 | -$ActionFileDefaultTemplate RSYSLOG_TraditionalFileFormat | ||
| 18 | - | ||
| 19 | -# Include all config files in /etc/rsyslog.d/ | ||
| 20 | -$IncludeConfig /etc/rsyslog.d/*.conf | ||
| 21 | - | ||
| 22 | -# Turn off message reception via local log socket; | ||
| 23 | -# local messages are retrieved through imjournal now. | ||
| 24 | -$OmitLocalLogging on | ||
| 25 | - | ||
| 26 | -# File to store the position in the journal | ||
| 27 | -$IMJournalStateFile imjournal.state | ||
| 28 | - | ||
| 29 | -#### RULES #### | ||
| 30 | - | ||
| 31 | -# Log anything (except mail) of level info or higher. | ||
| 32 | -# Don't log private authentication messages! | ||
| 33 | -*.info;mail.none;authpriv.none;cron.none /var/log/messages | ||
| 34 | - | ||
| 35 | -# The authpriv file has restricted access. | ||
| 36 | -authpriv.* /var/log/secure | ||
| 37 | - | ||
| 38 | -# Log all the mail messages in one place. | ||
| 39 | -mail.* -/var/log/maillog | ||
| 40 | - | ||
| 41 | -# Log cron stuff | ||
| 42 | -cron.* /var/log/cron | ||
| 43 | - | ||
| 44 | -# Everybody gets emergency messages | ||
| 45 | -*.emerg :omusrmsg:* | ||
| 46 | - | ||
| 47 | -# Save news errors of level crit and higher in a special file. | ||
| 48 | -uucp,news.crit /var/log/spooler | ||
| 49 | - | ||
| 50 | -# Save boot messages also to boot.log | ||
| 51 | -local7.* /var/log/boot.log | ||
| 52 | - | ||
| 53 | -# SPB logs | ||
| 54 | -# Social | ||
| 55 | -if $fromhost-ip=='<%= node['peers']['social']%>' then /var/log/spb/social/social.log | ||
| 56 | \ No newline at end of file | 0 | \ No newline at end of file |
| @@ -0,0 +1,11 @@ | @@ -0,0 +1,11 @@ | ||
| 1 | +# Setting up dir to storage the logs from SPB env | ||
| 2 | +# Dir to storage Social logs | ||
| 3 | +if $fromhost-ip=='<%= node['peers']['social']%>' then /var/log/spb/social/social.log | ||
| 4 | +# Dir to storage Email logs | ||
| 5 | +if $fromhost-ip=='<%= node['peers']['email']%>' then /var/log/spb/email/email.log | ||
| 6 | +# Dir to storage database logs | ||
| 7 | +if $fromhost-ip=='<%= node['peers']['database']%>' then /var/log/spb/database/database.log | ||
| 8 | +# Dir to storage integration logs | ||
| 9 | +if $fromhost-ip=='<%= node['peers']['integration']%>' then /var/log/spb/integration/integration.log | ||
| 10 | +# Dir to storage reverseproxy logs | ||
| 11 | +if $fromhost-ip=='<%= node['peers']['reverseproxy']%>' then /var/log/spb/reverseproxy/reverseproxy.log |