cant to pipe attachment to sendmail using headers
Hi
I am having troubles with sendmail, whereby i cant pipe my attachment to the email i am sending. here is the command i am using; where filename is attachment and tempfile is the file that contains the header information. uuencode /tmp/$filename /tmp/$filename | sendmail -t < /tmp/$tempfile i am using sendmail as i need to mask the sender address. any help is appreciated regards brad |
You are piping with a "|" and redirecting input from a file with a "<" at the same time... Your 'sendmail' program can't get its input from 2 sources.
A pipe should be enough, like in the following example: base64 $filename | sendmail -i recipient@address.com More generally, a pipe is used when you want the output of one program to go in as input to the second program, and input redirection from files (with "<") only works when you have a real file on the disk with the pre-made input for the program. |
All times are GMT -5. The time now is 02:58 PM. |