blob: 25d0f62225e9725a1b33ce72c4f8aa7356104eda (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
#!/bin/sh
LOG_USER="qmaill"
LOG_GROUP=`id -g ${LOG_USER}`
LOG_NAME=`basename ${PWD%/log}`
LOG_DIR="/var/log/${LOG_NAME}"
if [ ! -d "${LOG_DIR}" ]; then
mkdir -p "${LOG_DIR}"
chown ${LOG_USER}:${LOG_GROUP} "${LOG_DIR}"
echo "Creating log dir for ${LOG_NAME}:"
ls -ld "${LOG_DIR}"
fi
exec 2>&1
exec setuidgid ${LOG_USER} multilog t s2000000 "${LOG_DIR}"
|