Forwarding email to a script

software development

#1

Hello folks,

After checking with customer support some time back and experimenting exaustively, the only way they and I found to foward an email to a script for processing, is by using Procmail.

I am familiar with Procmail and by setting up a .forward file to route the email through Procmail and a .procmailrc file to contain recipes to direct the delivery from Procmail to wherever I want, in my root directory, I am able to foward emails to a script.

The problem is that only emails addressed to, or forwarded to, the original email address DH set up for me, will see the .forward file. Any other email address I set up in the control panel, even in the same domain, get deliverred in such a way that they do not see the .forward file in my home directory and thus, are not routed through Procmail.

In other control panels, such as cpanel for instance, you are able to set up forwards for any email address through a pipe and thus, you can forward the emails directly to any script on your site, by piping to the full path to the script.

The forwarding system of DH does not permit you to foward to anything other than an email address. (I suppose it looks for the @ sign). The result, at any event, is that you cannot forward to a pipe and a full path to a script.

Does anyone know about a workaround for this,? Or is there no way to forward an email to a script other than through the email address DH originally set up?

TIA for any info.

Cordially,

Eagle

[b]Eagle[/b] Florida, USA "If you think you can or if you think you can't, you are right"


#2

With DreamHost you can provide your own procmail filters by uploading them to the user account for the mailbox. Obviously with a mailbox-only user you cannot since there is no FTP/SFTP/shell access.

Forward-only addresses bypass mailbox processing which means you need setup the address to forward to a mailbox address that has a procmail filter.

:cool: openvein.org -//- One-time [color=#6600CC]$50.00 discount[/color] on [color=#0000CC]DreamHost[/color] plans: Use ATROPOS7


#3

Hello Atropos7:

Thank you for replying to my post. I appreciate it.

I am however, somewhat confused. I use the same username, with FTP, SFTP and shell access for a bunch of different domains, including the one DH set up for me.

I have a .forward and a .procmailrc in my root directory. I have set up several fully hosted email addresses, both in the original domain and in other domains that have the same username.

However, mail addressed to any fully-hosted email address, whether in the original domain or another domain with the same username, other than the original email address DH set up for me, does not see the .forward file and therefore does not get routed through Procmail.

This behavior, as I understand it, is not compatible with what you say and I quote:
“With DreamHost you can provide your own procmail filters by uploading them to the user account for the mailbox. Obviously with a mailbox-only user you cannot since there is no FTP/SFTP/shell access.”

What is a mailbox-only user? I have only one user. The email addresses do not use a username, they use the full email address instead. They are however, assigned to a user, which in my case, is the one and only.

I am not talking about forward-only addresses, but fully-hosted addresses with one and the same username. Forward-only address is what I had to do for my work-around, forwarding another address to the original email address DH set up for me, so that the message would be routed through Procmail. I cannot understand your statement:
“Forward-only addresses bypass mailbox processing which means you need setup the address to forward to a mailbox address that has a procmail filter.”

Since there is a Procmail filter in the root directory that serves many domains with the same username. Am I being dense and missing something? Why does only the email address DH set up for me gets routed through the .forward file, while not other fully-hosted email addresses with the same username, even for the same domain?

TIA for any help.

Cordially,

Eagle

[b]Eagle[/b] Florida, USA "If you think you can or if you think you can't, you are right"