<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<p>Hello,</p>
<p>for convenience, I added command line parameters to set #!subst,
#!substdef and #!substdefs expressions - details about them in the
wiki:</p>
<p> * <a
href="https://www.kamailio.org/wiki/cookbooks/devel/core#subst">https://www.kamailio.org/wiki/cookbooks/devel/core#subst</a></p>
<p>It is only in master branch, being new features, but maybe you
can test and report if they work fine. It should be like:</p>
<p>kamailio
--subst=<a class="moz-txt-link-rfc2396E" href="mailto:%DBURL%mysql://admin:mypass@db.mydomaincom/kamailio%">"%DBURL%mysql://admin:mypass@db.mydomaincom/kamailio%"</a> ...</p>
<p>And in kamailio.cfg:</p>
<p>modparam("acc", "db_url", "DBURL")<br>
...<br>
modparam("sqlops","sqlcon", "cb=>DBURL")<br>
...<br>
modparam("sqlops","sqlcon", "asg=>DBURL")<br>
</p>
Cheers,<br>
Daniel<br>
<div><font face="courier new, monospace"><br>
</font></div>
<div class="moz-cite-prefix">On 12.05.19 23:51, David Villasmil
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CAFGRPVqMxkE3GwMj8TKz_yozt_KW9yd0Y-PZVYts9XcD-+Owwg@mail.gmail.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div dir="ltr">
<div dir="ltr">
<div dir="ltr">
<div dir="ltr">
<div dir="ltr">
<div dir="ltr">
<div dir="ltr">
<div dir="ltr">
<div dir="ltr">
<div dir="ltr">
<div>Finally figured out how to do it:</div>
<div><br>
</div>
<div>cfg:</div>
<div><font face="courier new, monospace">modparam("acc",
"db_url", DBURL)<br>
</font></div>
<div><font face="courier new, monospace">...</font></div>
<div>
<div><font face="courier new, monospace">modparam("sqlops","sqlcon",
CBDBURL)</font></div>
<div><font face="courier new, monospace">...</font></div>
<div><font face="courier new, monospace">modparam("sqlops","sqlcon",
ASGDBURL)</font></div>
</div>
<div><br>
</div>
<div>and startup:</div>
<div><br>
</div>
<div><font face="courier new, monospace">kamailio
-f /etc/kamailio/kamailio.cfg -E \</font></div>
<div><font face="courier new, monospace"> -A
'DBURL="mysql://</font><span
style="font-family:"courier
new",monospace">admin:mypass@db.</span><span
style="font-family:"courier
new",monospace">mydomaincom/kamailio</span><font
face="courier new, monospace">"' \</font></div>
<div><font face="courier new, monospace"> -A
"CBDBURL=\"cb=></font><span
style="font-family:"courier
new",monospace">admin:mypass@db.</span><span
style="font-family:"courier
new",monospace">mydomaincom/kamailio</span><font
face="courier new, monospace">\"" \</font></div>
<div><font face="courier new, monospace"> -A
'ASGDBURL=\"asg=></font><span
style="font-family:"courier
new",monospace">admin:mypass@db.</span><span
style="font-family:"courier
new",monospace">mydomaincom/kamailio\</span><font
face="courier new, monospace">"' -DDDD
2>&1</font><br>
</div>
<div><font face="courier new, monospace"><br>
</font></div>
<div><font face="courier new, monospace">Now
let's try and put that on the startup
systemd script.</font></div>
<div><font face="courier new, monospace"><br>
</font></div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0px 0px
0px 0.8ex;border-left:1px solid
rgb(204,204,204);padding-left:1ex">
<div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0px
0px 0px 0.8ex;border-left:1px solid
rgb(204,204,204);padding-left:1ex">
<div bgcolor="#FFFFFF"> </div>
</blockquote>
</div>
</blockquote>
</div>
</div>
</div>
</div>
</div>
</blockquote>
<pre class="moz-signature" cols="72">--
Daniel-Constantin Mierla -- <a class="moz-txt-link-abbreviated" href="http://www.asipto.com">www.asipto.com</a>
<a class="moz-txt-link-abbreviated" href="http://www.twitter.com/miconda">www.twitter.com/miconda</a> -- <a class="moz-txt-link-abbreviated" href="http://www.linkedin.com/in/miconda">www.linkedin.com/in/miconda</a></pre>
</body>
</html>