[Freeswitch-users] Upload file in Lua background

Sonnie basmo13 at yahoo.co.uk
Wed Feb 21 19:48:47 UTC 2018


 I'm writing some IVR in Lua  and trying to execute some code while the main program continues execution.    I've tried       ...    -- aws is AWS Command Line Interface    io.popen("aws s3 cp " ..  s3_src .. " ".. s3_dst)    os.execute("aws s3 cp " ..  s3_src .. " ".. s3_dst)    ... -- program execution continues    
Even tried  passing it off to a shell script(`s3_upload`)
    os.execute("s3_upload " ..  s3_src .." " .. s3_dst)    io.popen("s3_upload " ..  s3_src .. " ".. s3_dst)
I've tried 
 session:execute("bgsystem","s3_upload " ..  s3_src .. " ".. s3_dst )


If i use the Lua Interactive shell to run these commands independently, it works.
would appreciate any assistance.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20180221/3ffb384d/attachment.html>


More information about the FreeSWITCH-users mailing list