2019-10-29 15:38:23 +05:30
|
|
|
#!/bin/sh
|
|
|
|
. ./test.rc
|
|
|
|
|
|
|
|
if [ x"${srcdir}" = x ]; then
|
|
|
|
srcdir=.
|
|
|
|
fi
|
|
|
|
|
2019-11-02 16:17:24 +05:30
|
|
|
mkdir -p ${CONFD}
|
2019-10-30 21:44:29 +05:30
|
|
|
cat <<EOF > ${CONF}
|
2019-11-02 16:17:24 +05:30
|
|
|
# Nothing here yo
|
|
|
|
include ${CONFD}/*.conf
|
|
|
|
EOF
|
|
|
|
|
|
|
|
cat <<EOF > ${CONFD}/foo.conf
|
|
|
|
# Local log file, avoid sync to disk
|
2019-10-29 15:38:23 +05:30
|
|
|
*.* -${LOG}
|
2019-11-02 16:17:24 +05:30
|
|
|
EOF
|
|
|
|
|
|
|
|
cat <<EOF > ${CONFD}/bar.conf
|
|
|
|
# For remote logging
|
2019-10-30 21:44:29 +05:30
|
|
|
*.* @127.0.0.2
|
2019-10-29 15:38:23 +05:30
|
|
|
EOF
|
|
|
|
|
2019-10-30 21:44:29 +05:30
|
|
|
../src/syslogd -b :${PORT} -d -n -f ${CONF} -p ${SOCK} &
|
|
|
|
echo "$!" > ${PID}
|
2019-10-29 15:38:23 +05:30
|
|
|
|
|
|
|
sleep 1
|