add command line
This commit is contained in:
parent
21f60ecfdf
commit
28fe0cb271
10
commands/exim_passwd.sh
Normal file
10
commands/exim_passwd.sh
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
echo "Username: "
|
||||||
|
read username
|
||||||
|
echo "Domain: "
|
||||||
|
read domain
|
||||||
|
|
||||||
|
echo "Password: "
|
||||||
|
userdbpw -md5 | userdb "$username@$domain" set systempw
|
||||||
|
makeuserdb
|
12
commands/exim_useradd.sh
Normal file
12
commands/exim_useradd.sh
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
echo "Username: "
|
||||||
|
read username
|
||||||
|
echo "Domain: "
|
||||||
|
read domain
|
||||||
|
|
||||||
|
echo "$username" >> "/etc/exim4/domains/$domain"
|
||||||
|
echo "Password: "
|
||||||
|
userdb "$username@$domain" set uid=$(id -u mail) gid=$(id -g mail) home="/var/vmail/$domain/$username" mail="/var/vmail/$domain/$username"
|
||||||
|
userdbpw -md5 | userdb "$username@$domain" set systempw
|
||||||
|
makeuserdb
|
10
commands/exim_userdel.sh
Normal file
10
commands/exim_userdel.sh
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
echo "Username: "
|
||||||
|
read username
|
||||||
|
echo "Domain: "
|
||||||
|
read domain
|
||||||
|
|
||||||
|
sed "/$username/d" "/etc/exim4/domains/$domain"
|
||||||
|
userdb "$username@$domain" del
|
||||||
|
makeuserdb
|
@ -1,4 +1,4 @@
|
|||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
date >> /var/log/exim4/sa-learn
|
date >> /var/log/exim4/sa-learn
|
||||||
find /var/vmail -type d -name '.Junk' | xargs -I junk sa-learn --spam junk/{cur,new} >> /var/log/exim4/sa-learn
|
find /var/vmail -type d -name '.Junk' | xargs -I junk sa-learn --spam junk/{cur,new} >> /var/log/exim4/sa-learn
|
||||||
|
Loading…
Reference in New Issue
Block a user