<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Config Script for Thirdlane?]]></title><description><![CDATA[<p dir="auto">I'm running FOP2 in a Thirdlane multi-tenant environment.  We have been running it for some time now, and when I implemented it I had a config script for Thirdlane. But, I can't find that script.  Is there any chance it is still floating around somewhere?  Even if it isn't a complete script I would like to take a look to see if there is a way to automatically build configuration files from a Thirdlane environment.</p>
<p dir="auto">Thanks!<br />
Dan</p>
]]></description><link>http://localhost:4567/topic/683/config-script-for-thirdlane</link><generator>RSS for Node</generator><lastBuildDate>Tue, 27 Oct 2026 04:56:32 GMT</lastBuildDate><atom:link href="http://localhost:4567/topic/683.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 16 Mar 2011 17:01:20 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Config Script for Thirdlane? on Tue, 16 Oct 2012 23:38:30 GMT]]></title><description><![CDATA[<p dir="auto">Most proably the script will require some tweaking. Run them and inspect the output to find out what you have.</p>
]]></description><link>http://localhost:4567/post/2993</link><guid isPermaLink="true">http://localhost:4567/post/2993</guid><dc:creator><![CDATA[nicolas]]></dc:creator><pubDate>Tue, 16 Oct 2012 23:38:30 GMT</pubDate></item><item><title><![CDATA[Reply to Config Script for Thirdlane? on Tue, 16 Oct 2012 12:37:15 GMT]]></title><description><![CDATA[<p dir="auto">I'm using a single tenant thirdlane installation, will this change how the scripts work?</p>
]]></description><link>http://localhost:4567/post/2992</link><guid isPermaLink="true">http://localhost:4567/post/2992</guid><dc:creator><![CDATA[steedman]]></dc:creator><pubDate>Tue, 16 Oct 2012 12:37:15 GMT</pubDate></item><item><title><![CDATA[Reply to Config Script for Thirdlane? on Tue, 16 Oct 2012 11:49:35 GMT]]></title><description><![CDATA[<p dir="auto">You are right, the script to execute in fop2.cfg is <a href="http://autoconfig-users-thirdlane.pl" rel="nofollow ugc">autoconfig-users-thirdlane.pl</a></p>
<p dir="auto">You also need to create a file named automatic-thirdlane-buttons.cfg with the contents:</p>
<p dir="auto">#exec <a href="http://autoconfig-buttons-thirdlane.pl" rel="nofollow ugc">autoconfig-buttons-thirdlane.pl</a></p>
<p dir="auto">Now, those are not fully features, they are to be used as a base to adapt to your system/requirements. Read the scripts , run them in the console, inspect their output.</p>
<p dir="auto">They will create a basic multi tenant setup, with users for each tenant that is defined in a separate panel-context, so you have to login with ?context=tenant in the fop2 url.</p>
<p dir="auto">Best regards,</p>
]]></description><link>http://localhost:4567/post/2991</link><guid isPermaLink="true">http://localhost:4567/post/2991</guid><dc:creator><![CDATA[nicolas]]></dc:creator><pubDate>Tue, 16 Oct 2012 11:49:35 GMT</pubDate></item><item><title><![CDATA[Reply to Config Script for Thirdlane? on Mon, 15 Oct 2012 20:58:34 GMT]]></title><description><![CDATA[<p dir="auto">I don't mean to revive an old thread, but I cant seem to get this to work.  Are there new scripts to use with thirdlane?  and did you mean to #exec <a href="http://autoconfig-users-thirdlane.pl" rel="nofollow ugc">autoconfig-users-thirdlane.pl</a> in fop2.cfg?   or is <a href="http://autoconfig-buttons-thirdlane.pl" rel="nofollow ugc">autoconfig-buttons-thirdlane.pl</a> correct?  I have tried both.</p>
]]></description><link>http://localhost:4567/post/2990</link><guid isPermaLink="true">http://localhost:4567/post/2990</guid><dc:creator><![CDATA[steedman]]></dc:creator><pubDate>Mon, 15 Oct 2012 20:58:34 GMT</pubDate></item><item><title><![CDATA[Reply to Config Script for Thirdlane? on Tue, 05 Jun 2012 00:04:19 GMT]]></title><description><![CDATA[<p dir="auto">You execute scripts via the #exec setting in fop2.cfg</p>
<p dir="auto">Look at the end of your fop2.cfg file, you probably have this:</p>
<p dir="auto">#exec <a href="http://autoconfig-users-freepbx.sh" rel="nofollow ugc">autoconfig-users-freepbx.sh</a></p>
<p dir="auto">change that to</p>
<p dir="auto">#exec <a href="http://autoconfig-buttons-thirdlane.pl" rel="nofollow ugc">autoconfig-buttons-thirdlane.pl</a></p>
<p dir="auto">Also, do not forget to set execute permissions to all .pl scripts</p>
<p dir="auto">chmod a+x *.pl</p>
]]></description><link>http://localhost:4567/post/2989</link><guid isPermaLink="true">http://localhost:4567/post/2989</guid><dc:creator><![CDATA[nicolas]]></dc:creator><pubDate>Tue, 05 Jun 2012 00:04:19 GMT</pubDate></item><item><title><![CDATA[Reply to Config Script for Thirdlane? on Sat, 02 Jun 2012 01:48:06 GMT]]></title><description><![CDATA[<p dir="auto">how do we set FOP2 to execute those scripts,    it doesn't seem like #exec works with perl</p>
]]></description><link>http://localhost:4567/post/2988</link><guid isPermaLink="true">http://localhost:4567/post/2988</guid><dc:creator><![CDATA[cyford33]]></dc:creator><pubDate>Sat, 02 Jun 2012 01:48:06 GMT</pubDate></item><item><title><![CDATA[Reply to Config Script for Thirdlane? on Fri, 01 Jun 2012 23:46:54 GMT]]></title><description><![CDATA[<p dir="auto">what do we do after we create these files?</p>
]]></description><link>http://localhost:4567/post/2987</link><guid isPermaLink="true">http://localhost:4567/post/2987</guid><dc:creator><![CDATA[cyford33]]></dc:creator><pubDate>Fri, 01 Jun 2012 23:46:54 GMT</pubDate></item><item><title><![CDATA[Reply to Config Script for Thirdlane? on Tue, 05 Apr 2011 12:00:05 GMT]]></title><description><![CDATA[<p dir="auto"><em><strong><a href="http://autoconfig-users-thirdlane.pl" rel="nofollow ugc">autoconfig-users-thirdlane.pl</a></strong></em></p>
<pre><code>#!/usr/bin/perl

$file = "/etc/asterisk/voicemail.conf";

open( CONFIG, "&lt;$file" ) or die("Could not open $file");

while (&lt;CONFIG&gt;) {
   chomp;
   $_ =~ s/^\s+//g;
   $_ =~ s/([^;]*)[;](.*)/$1/g;
   $_ =~ s/\s+$//g;

   if ( /^#/ || /^;/ || /^$/ ) {
       next;
   }    # Ignores comments and empty lines

   if (/^\Q[\E/) {
       s/\[(.*)\]/$1/g;
       $context = $_;
       if($context =~ /^default/) {
           $context =~ s/^default-//g;
           if($hubo&gt;0) {
               print "buttonfile=automatic-thirdlane-buttons.cfg $oldcontext\n\n";
               $hubo=0;
           }
           if($context ne "default") {
              print "[$context]\n";
           }
       }
   }
   if (/=&gt;/) {
       $_ =~ s/\s//g;
       @partes = split(/=&gt;/,$_,2);
       $exten = $partes[0];
       $resto = $partes[1];
       @partes = split(/,/,$resto,2);
       $secret = $partes[0];
       $oldcontext=$context;
       print "user=$exten:$secret:all\n";
       $hubo++;
   }

}
close(CONFIG);

print "buttonfile=automatic-thirdlane-buttons.cfg $oldcontext\n\n";
</code></pre>
<p dir="auto"><em><strong>automatic-thirdlane-buttons.cfg</strong></em></p>
<pre><code>#exec autoconfig-buttons-thirdlane.pl $1
</code></pre>
<p dir="auto"><em><strong><a href="http://autoconfig-buttons-thirdlane.pl" rel="nofollow ugc">autoconfig-buttons-thirdlane.pl</a></strong></em></p>
<pre><code>#!/usr/bin/perl

$file = "/etc/asterisk/users.txt";

$mycontext = $ARGV[0];

open( CONFIG, "&lt;$file" ) or die("Could not open $file");

while (&lt;CONFIG&gt;) {
   chomp;
   $_ =~ s/^\s+//g;
   $_ =~ s/([^;]*)[;](.*)/$1/g;
   $_ =~ s/\s+$//g;

   if ( /^#/ || /^;/ || /^$/ ) {
       next;
   }    # Ignores comments and empty lines

   if (/^\Q[\E/) {
       s/\[(.*)\]/$1/g;
       $context = $_;
       @partes = split (/-/,$context,2);
       $context= $partes[0];
       $extension = $partes[1];
       if($context eq $mycontext) {
          $dale=1;
       } else {
          $dale=0;
       }
   } else {
       if($dale==1) {
         my ($key,$val) = split(/=/,$_,2);
         $config-&gt;{$mycontext}{$extension}{$key}=$val;
       }
   }
}
close(CONFIG);
while ( my ( $uno, $dos ) = each( %{ $config-&gt;{$mycontext} } ) ) {
   $label = $dos-&gt;{first_name}." ".$dos-&gt;{last_name};
   $exten = $dos-&gt;{ext};
   $ctx = "from-inside-$mycontext";
   $mbox = $dos-&gt;{mailbox};
   $chan = $dos-&gt;{phones};
   print "[$chan]\n";
   print "type=extension\n";
   print "extension=$exten\n";
   print "context=$ctx\n";
   print "label=$label\n";
   print "mailbox=$mbox\n\n";
}

</code></pre>
]]></description><link>http://localhost:4567/post/2986</link><guid isPermaLink="true">http://localhost:4567/post/2986</guid><dc:creator><![CDATA[nicolas]]></dc:creator><pubDate>Tue, 05 Apr 2011 12:00:05 GMT</pubDate></item></channel></rss>