Qmail - Forward email without attachment

677 Views Asked by At

I have pretty standard Qmail toaster installation. I'm using the dot files to set up mail forwarding for my account, so when I recieve an e-mail, this e-mail stays in my mailbox and is also forwarded to another email address. Easy, you say. And yes, it is, it is working fine ... except ... That this another email adress is actually a cell phone number, so I get an SMS notification about each email I recieve.

But, as our phone provider limits the size of an SMS, if I recieve an email with attachment, Qmail tries to forward it to my mobile phone, but this fails, the error message gets back to original email sender and he thinks the email was not delivered at all.

I haven't found any solution to this, but I came to an idea - if there is a possibility to LIMIT the Qmail, so he doesn't forward the specific type of emails (in my case, emails with attachments) ? Or somehow restrict him from sending back the error messages from these forwards ?

1

There are 1 best solutions below

0
On BEST ANSWER

Stripmime
http://www.phred.org/~alex/stripmime.html

.qmail-default:

| /usr/local/bin/stripmime.pl | /home/vpopmail/bin/vdelivermail '' [email protected]

or

Demime
http://scifi.squawk.com/demime.html (link not working anymore)

.qmail-default:

|/var/qmail/bin/demime -8 [email protected]