1
2
mirror of https://github.com/vimagick/dockerfiles synced 2024-06-20 13:58:42 +00:00

update rsyslog

This commit is contained in:
kev 2016-10-29 16:22:21 +08:00
parent fcd4b35ea5
commit ebe080bd1f
2 changed files with 17 additions and 4 deletions

@ -3,7 +3,6 @@
#
FROM alpine
MAINTAINER kev <noreply@easypi.info>
RUN set -xe \
@ -18,6 +17,7 @@ RUN set -xe \
} >> /etc/rsyslog.conf
VOLUME /var/log
WORKDIR /var/log
EXPOSE 514/tcp \
514/udp

@ -1,6 +1,8 @@
rsyslog
=======
[RSYSLOG][1] is the rocket-fast system for log processing.
## docker-compose.yml
```yaml
@ -18,8 +20,19 @@ rsyslog:
```bash
$ docker-compose up -d
$ docker-compose exec rsyslog sh
>>> logger -t debug hello world
>>> tail /var/log/messages
2016-10-29T07:52:15.177918+00:00 c88f52cf86b6 debug: hello world
>>> pwd
/var/log
>>> touch maillog
>>> tail -f /var/log/maillog
2016-10-29T08:17:34+00:00 172.17.0.1 root: hello
2016-10-29T08:17:41+00:00 172.17.0.1 root: world
^C
>>> exit
$ logger -n localhost -p mail.debug hello
$ logger -n localhost -p mail.info world
```
[1]: http://www.rsyslog.com/