nedi,
I *think* you need bash for the "-e" option to the echo built-in
command.
So, you could try creating a script file, email_in.sh
exten =>12,1,System(/whereever/email_in.sh "${CALLERID}" "${DATETIME}")
In a file "email_in.sh" between the -----'s...
--------
#!/bin/bash
echo -e "Subject: Incoming call from:$1\nPlaced: $2" | /usr/sbin/
msmtp [EMAIL PROTECTED]
exit 0
-------
Then set permissions...
$ chmod 755 email_in.sh
That's it, give it a try and let me know what I screwed-up. <smile>
Lonnie
PS: you can test this outside of asterisk and see if you get mail.
./email_in.sh "11 <11>" "17012007-23:57:30"
On Jan 17, 2007, at 5:27 PM, Nedi wrote:
> Hi ,
> I try to configure email notification for missed calls if one call me
> and not let me a voicemail.
>
> In extensions.conf I have :
> -----------------------------------------------------
> exten =>12,1,System(/bin/echo -e "Subject: 'Incoming call from
> :${CALLERID} \\r Placed: ${DATETIME}'" | msmtp [EMAIL PROTECTED])
> exten =>12,2,Dial(SIP/12,17,r)
> exten =>12,3,Answer
> exten =>12,4,Playback(vm-nobodyavail)
> exten =>12,5,Voicemail(12)
> exten =>12,6,Hangup
> -----------------------------------------------------------
> If I call from internal 11 to internal 12 I get in asterisk
> console this :
> -------------------------------------------------------------------
> allversal*CLI> Jan 17 23:57:30 WARNING[25323]: app_system.c:108
> system_exec_helper: Unable to execute '/bin/echo -e "Subject:
> 'Incoming
> call from :"11" <11> \r Placed: 17012007-23:57:30" | msmtp
> [EMAIL PROTECTED]'
>
> --------------------------------------------------
> could someone tell me why ??
>
> regards
> nedi
>
>
>
>
> _______________________________________________
> Astlinux-users mailing list
> [email protected]
> http://lists.kriscompanies.com/mailman/listinfo/astlinux-users
>
> Donations to support AstLinux are graciously accepted via PayPal to
> [EMAIL PROTECTED]
>
> REMEMBER: AstLinux mailing lists are moving soon:
>
> http://sourceforge.net/mail/?group_id=170462
>
> Please move any discussions ASAP!
>
_______________________________________________
Astlinux-users mailing list
[email protected]
http://lists.kriscompanies.com/mailman/listinfo/astlinux-users
Donations to support AstLinux are graciously accepted via PayPal to [EMAIL
PROTECTED]
REMEMBER: AstLinux mailing lists are moving soon:
http://sourceforge.net/mail/?group_id=170462
Please move any discussions ASAP!