Hi,
I have asterisk 1.4.4 installed on a fritzbox 7170. I use exten => 224,1,system,/var/asterisk/cb/test2.sh to call the following shell script
#!/bin/sh
echo "test" > /var/spool/asterisk/cbtmp/testing.txt
myvar="1111"
/bin/sed -e " s/REPLACEME/$myvar/" /var/asterisk/cb/isdn3_REPLACEME.call > /var/spool/asterisk/cbtmp/t.call
#mv /var/spool/asterisk/cbtmp/t.call /var/spool/asterisk/outgoing
Calling the script from outside Asterisk works fine, calling similar scripts that don’t use sed, but just copy and move stuff, works, too. But this script yields an empty file t.call once called from the extension context. The testing.txt has the desired text - so writing to the dir as such works.
Any suggestions, why I can’t use sed ? Or is it something else ?
Cheers for the help!