Project

General

Profile

Postfix e-mail failure [cannot append message to file /path/to/rdm-mailhandler.rb <command>: cannot open file: Permission denied)

Added by Syn Admin almost 15 years ago

Hey everyone,

I've set up an MTA to relay messages from my own network to our Exchange server and beyond, and while handling mail, I've instructed it, under /etc/aliases, to handle e-mail destined for redmine with the following directive:


helpdesk:    "/path/to/rdm-mailhandler.rb --url http://<myredmineurl.com> --key <the_key> --project helpdesk" 


But whenever I attempt to send an e-mail to this address:

[root@<mailhost> ~]# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 mailhost ESMTP Postfix
ehlo localhost
250-<mailhost>
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
mail from:<user><mydomain>.com
250 2.1.0 Ok
rcpt to: helpdesk
<mydomain>.com
250 2.1.5 Ok
data
354 End data with <CR><LF>.<CR><LF>
TESTING
.
250 2.0.0 Ok: queued as 76B5D6803F

Here is the log from this mail server:

Dec  1 10:57:28 <mailhost> postfix/smtpd[27674]: connect from localhost.localdomain[127.0.0.1]
Dec  1 10:57:58 <mailhost> postfix/smtpd[27674]: 76B5D6803F: client=localhost.localdomain[127.0.0.1]
Dec  1 10:58:06 <mailhost> postfix/cleanup[27679]: 76B5D6803F: message-id=<20091201155758.76B5D6803F@<mailhost>>Dec  1 10:58:06 <mailhost> postfix/qmgr[27668]: 76B5D6803F: from=<user>@<mydomain>.com, size=344, nrcpt=1 (queue active)Dec  1 10:58:06 <mailhost> postfix/local[27680]: warning: dict_nis_init: NIS dom
ain name not set - NIS lookups disabledDec  1 10:58:06 <mailhost> postfix/local[27680]: 76B5D6803F: to=helpdesk@<mydoma
in>.com, relay=local, delay=14, delays=14/0.01/0/0.07, dsn=5.2.0, status=bounced (cannot append message to file /path/to/rdm-mailhandler.rb --url http://<myredm
ineurl.com> --key <the_key> --project helpdesk: cannot open file: Permission denied)

And here are the permissions of the rdm-mailhandler.rb:

[root@<mailhost> ~]# ls -ld /path/to/rdm-mailhandler.rb
-rwxr-xr-x 1 777 root 4294 Dec  1 10:00 /path/to/rdm-mailhandler.rb