1
0
mirror of /repos/baseimage-docker.git synced 2025-12-30 08:01:31 +01:00

Fix syslog-ng.

The system() source in the default syslog-ng config file does
not work in Docker because it tries to access /proc/kmsg,
which is not allowed due to Docker's privileges. We replace
it by a source that only reads from /dev/log.
This commit is contained in:
Hongli Lai (Phusion) 2014-05-12 17:29:45 +02:00
parent 612b1504af
commit b56693beb3
No known key found for this signature in database
GPG Key ID: 2AF96EB85EF4DA0D

View File

@ -21,6 +21,9 @@ mkdir /etc/service/syslog-ng
cp /build/runit/syslog-ng /etc/service/syslog-ng/run
mkdir -p /var/lib/syslog-ng
cp /build/config/syslog_ng_default /etc/default/syslog-ng
# Replace the system() source because inside Docker we
# can't access /proc/kmsg.
sed -i -E 's/^(\s*)system\(\);/\1unix-stream("\/dev\/log");/' /etc/syslog-ng/syslog-ng.conf
## Install logrotate.
$minimal_apt_get_install logrotate