[asterisk-dev] Asterisk configuration - client/server protocol

Stig Even Larsen stig at nimra.no
Thu Jul 19 06:25:57 CDT 2007


Eric "ManxPower" Wieling wrote:
> Stig Even Larsen wrote:
>  > Hi,
>  >
>  > It would be nice to have a client/server protocol for generating the
>  > internal Asterisk configuration structures from any source
>  > (sql,ldap,web-services,etc).
>  > This way it would be very easy to tightly integrate Asterisk with
>  > existing/new systems.
>  >
>  > Is this something worth following up?
>
> I believe that is called ARA (Asterisk Realtime Architecture aka Realtime).
>

I think I was too implicit in my initial post.
This is not the same as Realtime. As far as I know the only supported  
realtime medium is SQL/LDAP. What I'm suggesting is a more dynamic way  
of getting and updating configuration (static and realtime). My  
thought is that Asterisk could "request" XML file from any source for  
configuration at startup/reload.

Consider the following configuration option.

extconfig.conf
sip.conf => xml, https://some.address/sip.conf.xml
extentions.conf => xml, http://some.address/extensions.conf.xml

extensions.conf.xml
<asterisk>
   <extensions>
     <general>
       <writeprotect>no</writeprotect>
       <autofallthrough>yes</autofallthrough>
       .
       .
       .
     </general>
     <globals>

     </globals>
     <exten>
       <id>1234</id>
       <prio>
         <id>1</id>
         <application>Dial(SIP/myphone)</application>
         <timeout>25</timeout>
         <param>Ttr</param>
       </prio>
       <prio>
         <id>n</id>
         <application>Dial(SIP/operator)</application>
         <timeout>300</timeout>
         <param>Ttr</param>
       </prio>
       <prio>
         <id>n</id>
         <application>Hangup</application>
       </prio>
     </exten>

     <exten>
       <id>1000</id>
       <prio>
         <id>1</id>
         <application>Dial(SIP/operator)</application>
         <timeout>15</timeout>
         <param>Ttr</param>
       </prio>
       <prio>
         <id>n</id>
         <application>Dial(SIP/otherphone)</application>
         <timeout>300</timeout>
         <param>Ttr</param>
       </prio>
     </exten>

   </extensions>
</asterisk>

sip.conf.xml

<asterisk>
   <sip>
     <general>
       <context>incoming</context>
       <bindport>5060</bindport>
       <register>
         <username>account1</username>
         <password>DfNB471rG</password>
         <server>sip.asterisk.org</server>
         <context>test-context</context>
       </register>
       .
       .
       .
     <peer>
       <type>friend</type>
       <context>default</context>
       <callerid>
         <name>Stig Even Larsen</name>
         <number>70111511</number>
       </callerid>
       <secret>mypassword</secret>
       <nat>yes</nat>
       .
       .
       .
     </peer>
     </general>

   </sip>
</asterisk>

This way asterisk configuration could be configured via any system.









More information about the asterisk-dev mailing list