[asterisk-users] Conditional "includes" in iax.conf

Scott Stingel scott at evtmedia.com
Wed Jul 7 13:58:26 CDT 2010


On 7/7/2010 11:52 AM, Kevin P. Fleming wrote:
> On 07/07/2010 01:46 PM, Scott Stingel wrote:
>    
>> On 7/7/2010 11:25 AM, Danny Nicholas wrote:
>>      
>>> --
>>> Rather than trying to determine what system you are on, just make the
>>> included file be empty on all except the desired server.
>>>
>>>
>>>
>>>        
>> OK, thanks.  I thought I might have to do it that way, which is slightly
>> less desirable, as it makes the systems "different" from each other.
>>      
> You could also enable 'execincludes' in asterisk.conf, then use #exec to
> execute a small script (even just a shell script) that outputs the
> desired iax.conf content for the server it is running on. That's much
> easier and more effective than trying to put conditional logic and other
> programming constructs into the configuration file reader.
>
>    
Ok, thanks Kevin.  Something I haven't used before but will look into!





More information about the asterisk-users mailing list