Exchange receipients.sh: Difference between revisions
Clandmeter (talk | contribs) No edit summary |
(tidied up) |
||
Line 1: | Line 1: | ||
<pre> | |||
#!/bin/sh | #!/bin/sh | ||
Line 17: | Line 18: | ||
fi | fi | ||
fi | fi | ||
</pre> |
Revision as of 13:38, 22 May 2009
#!/bin/sh ### The minimal lines virtual.txt must have to generate the db MINLINES="50" ### The url to the receipients file URL="" wget "$URL" -qO /tmp/virtual.txt if [ -f /tmp/virtual.txt ]; then LINES=`cat /tmp/virtual.txt | wc -l` if [ "$LINES" -gt "$MINLINES" ]; then dos2unix /tmp/virtual.txt sed '/^\#/d; /^$/d' /tmp/virtual.txt > /etc/postfix/exchange_receipients postmap /etc/postfix/exchange_receipients fi fi