Because it is default from lua.conf.xml vanila example. But without ?.lua and without /?.lua I gave the same result 2014-10-03 19:18 GMT+04:00 Michael Jerris <mike@jerris.com>:
why do you have ?.lua at the end? what happens if you don't include that?
On Oct 3, 2014, at 9:20 AM, Борисов, Дмитрий <bordmi@rarus.ru> wrote:
I found some intrsting thing, maybe bug. I instruct mod_lua to seek for scripts in $${script_dir}/lua:
# cat lua.conf.xml <configuration name="lua.conf" description="LUA Configuration"> <settings>
<param name="module-directory" value="/usr/local/lib/lua/5.1/?.so"/> <param name="module-directory" value="/usr/local/lib/?.so"/> <param name="script-directory" value="$${script_dir}/lua/?.lua"/>
<param name="xml-handler-script" value="gen_dir_user_xml.lua"/> <param name="xml-handler-bindings" value="directory"/>
</settings> </configuration>
But in loading process i got next error message in logfile:
freeswitch.log: 2014-10-03 17:02:05.683593 [ERR] mod_lua.cpp:203 cannot open /usr/local/share/freeswitch/scripts/gen_dir_user_xml.lua: No such file or directory 2014-10-03 17:02:05.683599 [ERR] mod_lua.cpp:269 LUA script parse/execute error! 2014-10-03 17:02:05.683901 [ERR] mod_lua.cpp:203 cannot open /usr/local/share/freeswitch/scripts/gen_dir_user_xml.lua: No such file or directory 2014-10-03 17:02:05.683910 [ERR] mod_lua.cpp:269 LUA script parse/execute error! 2014-10-03 17:02:05.684191 [ERR] mod_lua.cpp:203 cannot open /usr/local/share/freeswitch/scripts/gen_dir_user_xml.lua: No such file or directory 2014-10-03 17:02:05.684196 [ERR] mod_lua.cpp:269 LUA script parse/execute error!
I put my lua scripts in right place (as described in config): # ls -la /usr/local/share/freeswitch/scripts/lua/gen_dir_user_xml.lua -rw-r--r-- 1 root wheel 1708 3 окт 16:17 /usr/local/share/freeswitch/scripts/lua/gen_dir_user_xml.lua
But FS seek for it in $${script_dir} place, where no my script: # ls -la /usr/local/share/freeswitch/scripts/gen_dir_user_xml.lua ls: /usr/local/share/freeswitch/scripts/gen_dir_user_xml.lua: No such file or directory
When my FF starts, it evals path from config right: freeswitch@voip-bsd-01.local> eval $${script_dir}/lua/ /usr/local/share/freeswitch/scripts/lua/
I can solve this problem simply by putting script to $${script_dir} (I tried, it works), but after that i loose possibility to sort my scripts.
Any thinks about?
-- Best regards, Борисов Дмитрий
_________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org http://www.freeswitchsolutions.com
Official FreeSWITCH Sites http://www.freeswitch.org http://confluence.freeswitch.org http://www.cluecon.com
FreeSWITCH-powered IP PBX: The CudaTel Communication Server http://www.cudatel.com
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
-- С уважением, Борисов Дмитрий