[sr-dev] [kamailio/kamailio] Kami Lua retrieving variable in configuration file (#2822)

jpskriver notifications at github.com
Thu Aug 12 05:53:24 CEST 2021


### Description
Suppose that there is an variable define in `kamailio-basic-kemi.cfg` with:
```
#!define MYVAR 1.2.3.4
```

Then in the `kamailio-basic-kemi-lua.lua`

- How can we get that variable?


### Possible Solutions
Is there any alternative solution like set global via app_lua parameter, example:
```
modparam("app_lua", "load", "/usr/local/etc/kamailio/lua/myscript.lua")
modparam("app_lua", "varset", "pstngw=s:sip:10.10.10.10")
```



-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2822
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-dev/attachments/20210811/6f329f45/attachment.htm>


More information about the sr-dev mailing list