Ensure to copy all rsyslogd configuration files.

This commit is contained in:
Jeremy Gardais 2018-01-30 16:59:36 +01:00
parent 10ff11e346
commit e28c606751
1 changed files with 7 additions and 7 deletions

View File

@ -1,9 +1,9 @@
#!/bin/sh #!/bin/sh
RSYSLOGD_CONF="$(dirname $0)/stretch/etc/rsyslog.conf" RSYSLOGD_CONF_SRC="$(dirname $0)/stretch/etc/rsyslog.conf"
RSYSLOGD_FILE="/etc/rsyslog.conf" RSYSLOGD_CONF_PATH="/etc/rsyslog.conf"
RSYSLOGD_SYSLOG_CONF="$(dirname $0)/stretch/etc/rsyslog.d/99syslog.conf" RSYSLOGD_INCLUDE_SRC="$(dirname $0)/stretch/etc/rsyslog.d/*"
RSYSLOGD_SYSLOG_FILE="/etc/rsyslog.d/99syslog.conf" RSYSLOGD_INCLUDE_PATH="/etc/rsyslog.d/"
LOGROTATE_CONF="$(dirname $0)/stretch/etc/logrotate.conf" LOGROTATE_CONF="$(dirname $0)/stretch/etc/logrotate.conf"
LOGROTATE_FILE="/etc/logrotate.conf" LOGROTATE_FILE="/etc/logrotate.conf"
@ -70,10 +70,10 @@ fi
### Rsyslog {{{ ### Rsyslog {{{
# Install new Rsyslog configuration # Install new Rsyslog configuration
if [ -f "${RSYSLOGD_FILE}" ]; then if [ -f "${RSYSLOGD_CONF_PATH}" ]; then
cp "${RSYSLOGD_CONF}" "${RSYSLOGD_FILE}" cp "${RSYSLOGD_CONF_SRC}" "${RSYSLOGD_CONF_PATH}"
fi fi
cp "${RSYSLOGD_SYSLOG_CONF}" "${RSYSLOGD_SYSLOG_FILE}" cp -- "${RSYSLOGD_INCLUDE_SRC}" "${RSYSLOGD_INCLUDE_PATH}"
# Restart Rsyslog service # Restart Rsyslog service
systemctl restart rsyslog systemctl restart rsyslog