Hi there,
I’m having issues setting up a post record script. Freepbx 2.11.0.0beta2.2 on Asterisk 11.2.1, call recording module 2.11.0.1. Hosted on Debian using Nginx. System functioning fine, including standard recording (the wavs are there).
The problem is triggering the post recording script, a little python thing I whipped up to convert it into mp3. The script has a shebang and proper permissions, runs fine from command prompt as the asterisk user.
I’ve configured it in the appropriate place in settings/advanced (and applied), but when it executes, it just doesn’t seem to actually execute.
The value I have set is:
/var/lib/asterisk/bin/convertaudio.py --file=’^{MIXMON_DIR}^{YEAR}/^{MONTH}/^{DAY}/^{CALLFILENAME}.^{MIXMON_FORMAT}’ --outputdir=/home/blah/audio
In startup, it says:
“[2013-01-29 16:39:18] VERBOSE[28146] pbx.c: == Setting global variable ‘MIXMON_POST’ to ‘/var/lib/asterisk/bin/convertaudio.py --file=’^{MIXMON_DIR}^{YEAR}/^{MONTH}/^{DAY}/^{CALLFILENAME}.^{MIXMON_FORMAT}’ --outputdir=/home/blah/audio’”
But when it executes, I only see:
[2013-01-29 16:41:25] VERBOSE[28243] app_mixmonitor.c: == Executing [/var/lib/asterisk/bin/convertaudio.py]
And nothing runs. The log file the code should write it if it runs at all is not touched.
If I put quotes around the entire phrase in settings, then I get:
[2013-01-29 16:22:59] VERBOSE[27607] app_mixmonitor.c: == Executing [/var/lib/asterisk/bin/convertaudio.py --file=’/var/spool/asterisk/monitor/2013/01/29/out-xxxx-xxx-20130129-x-1359436969.12.wav’ --outputdir=/home/blah/audio]
But still no output or evidence that the script has even run. What am I missing? I also tried wrapping it in a System() call, but that made no difference.
Is it something to do with using named arguments? Or am I missing something more obvious?
Thanks,
Patrick