• Inviting everyone who uses WordPress management tools in Plesk
    The Plesk team is conducting a 60-minute research session that includes an interview and a moderated usability test.
    To participate, please use this link .
    Your experience will help shape product decisions and ensure the tools better support real-world use cases.

setting up abuse and postmaster addresses on all domains?

michaellunsford

Regular Pleskian
I'd like to setup an abuse and postmaster address for all domains. All the different addresses should forward to the system administrator.

I can't find it in group operations. Is there another way to do this quickly, or will I have to manually add the addresses to each domain?
 
Hello,

You can do it with a script using :

/usr/local/psa/bin/mail.sh

You could do like this:

echo "select name from domains;" | mysql -u admin -p`cat /etc/psa/.psa.shadow ` psa > dom

remove the first line of the file

cat dom | awk '{print "/usr/local/psa/bin/mail.sh --create postmaster@"$1" OPTIONS_HERE";}' > script

sh script

OPTIONS_HERE can be found out at:

/usr/local/psa/bin/mail.sh --help

This is one solution , I am sure that there more elegant ones.
 
There's an easier and better solution for this.

Just put a .qmail-postmaster in each domain's folder, under the qmail root; containing the email address of the administrator.

Like this:

echo "[email protected]" > .qmail-postmaster
for key in `ls /var/qmail/mailnames/ | xargs`;do cp .qmail-postmaster /var/qmail/mailnames/$key/.qmail-postmaster;chown popuser:popuser /var/qmail/mailnames/$key/.qmail-postmaster;done


That way you have a postmaster alias for every domain, _AND_ the domain admin can't modify that alias.

I'm no qmail expert, but that seems to work for me.
 
Back
Top