diff --git a/Dockerfile b/Dockerfile index d6d5bae..0dcd726 100644 --- a/Dockerfile +++ b/Dockerfile @@ -13,4 +13,6 @@ ENV TARGET_PROTO="tcp" ENV TARGET_PORT="514" ENV DEBUG="0" +VOLUME [ "/extraconfig" ] + ENTRYPOINT ["/bin/sh", "/run.sh"] \ No newline at end of file diff --git a/README.md b/README.md index f80c330..6ffb16c 100644 --- a/README.md +++ b/README.md @@ -21,6 +21,10 @@ Variable | Default | Description TARGET_PORT | 514 | target server syslog port DEBUG | 0 | if != 0, every received log line is shown on stdout +## extra config files + +You can add some custom config file, by mounting the `/extraconfig` directory. Any file ending in `.conf` placed here will be added to rsyslog configuration. + ## run ```bash diff --git a/run.sh b/run.sh index 9967ea9..6052232 100644 --- a/run.sh +++ b/run.sh @@ -54,4 +54,10 @@ action(type="omfwd" protocol="tcp" target="${TARGET_HOST}" port="${TARGET_PORT}" EOF fi +# extra config +mkdir -p /extraconfig +cat >>/etc/rsyslog.conf <