#!/bin/sh
# Vadduers mail address and create backup mailbox
#anaylist S2
case "$1" in
--help)
#get help
echo "Usage: quseradd [yourname] [userquotasize]"
echo "Please attention this: Default Mail User's Passwd is [yourname]"
echo "So,You Must give your users notice and change their passwd :-)"
exit 1
esac
case "$2" in
"")
echo "Usage: quseradd [yourname] [userquotasize]"
echo "Please attention this: Default Mail User's Passwd is [yourname]"
echo "So,You Must give your users notice and change their passwd :-)"
exit 1
esac
vadduser $addr1 $1
vsetuserquota $addr1 $2
vadduser $addr2 $1
# Create some rules to contral mail actions
qmailfile=".qmail-"$1
echo "$addr2" > /home/vpopmail/domains/newlido.com/$qmailfile
qmaildir="/home/vpopmail/domains/newlido.com/"$1"/Maildir/"
echo "$qmaildir" >> /home/vpopmail/domains/newlido.com/$qmailfile
chmod 600 /home/vpopmail/domains/newlido.com/$qmailfile
chown vpopmail:vchkpw /home/vpopmail/domains/newlido.com/$qmailfile
阅读(738) | 评论(0) | 转发(0) |