[App_rpt-users] Running a shell script from a DTMF command?

Phil N6TCT phil.n6tct at gmail.com
Mon May 23 21:02:49 EDT 2011


Thanks to all who responded to me on this.  Brian Boyle sent me a note
off-list which seems to be the simplest solution:

999=cmd,/full/pathname/to/script

He further notes, "make sure execute permissions and such are ok.
restart app_rpt.  should be good to go."

I just tried it and it worked like a charm.  Thanks again!

Phil, N6TCT

P.S., Sorry for the delayed response, was climbing a mountain in
Nevada with the Black Rock Amateur Radio Association team to deploy a
solar-powered Beagleboard app_rpt system!

On Sat, May 21, 2011 at 1:53 PM, Ken <ke2n at cs.com> wrote:
> I have not seen any one try to answer this ...
> I imagine the preferred way to do this now is with the 'event handling'
> system
> http://ohnosec.org/drupal/node/176
>
>
> <action-spec> = <action>|<type>|<var-spec>
> If action is 'S' (for "shell command"), then action-spec is a shell command
> to be executed (if result is 1).
>
> You would have to figure out how to make the DTMF command constitute an
> 'event'
> It could be you have to go into the asterisk "dialplan" and use that part of
> things to set a variable.
>
> exten => 1234,5,rpt(2000,V,MYVAR=0)
>
> When the variable went true, courtesy of the asterisk dial plan, then rpt
> would run your shell script.
>
> GL
>
> Ken
>
>
>
>> -----Original Message-----
>> From: app_rpt-users-bounces at ohnosec.org [mailto:app_rpt-users-
>> bounces at ohnosec.org] On Behalf Of Phil N6TCT
>> Sent: Saturday, May 21, 2011 1:13 AM
>> To: app_rpt mailing list
>> Subject: [App_rpt-users] Running a shell script from a DTMF command?
>>
>> Hi gang.  Basic question here: what is the magic incantation to run an
>> arbitrary shell script from a DTMF command to an asterisk app_rpt
>> system?  E.g., I want to be able to dial *99999 or something and have
>> my asterisk system run /usr/local/bin/whatever.  I figure there has to
>> be a way to do this, but I haven't been able to spot it.  Thanks!
>>
>> Phil, N6TCT



More information about the App_rpt-users mailing list