0

The script I have designated FreePBX to call, when called directly from the CLI sends the email flawlessly. The emails are not triggered after a call takes place, however.

Background context: https://community.freepbx.org/t/solved-how-to-email-call-recordings-post-call-recording-script/26747/24

FreePBX 14.0.1.24

Asterisk 13.18.3

2 Answers2

0

In most cases asterisk pbx is running by asterisk user and running path can be virtualy anything.

So you need ensure

  1. Your script can run under asterisk user(permissions to logs file, read permissions for libs dirs etc etc)
  2. Your script path always full, from root. Library path full or system-wide.
arheops
  • 1,425
0

The problem in my case was the mutt configuration file .muttrc (mutt being the utility recommended for this application) was initially set up by root and not by asterisk and so asterisk did not know how to send out emails.

Solution: -make a new .muttrc file in the ~/ directory of the asterisk user (or cp the one from root if you have one there) -make sure all your mutt email credentials are stated in the .muttrc

For a rundown of how to configure mutt: http://nickdesaulniers.github.io/blog/2016/06/18/mutt-gmail-ubuntu/