<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">to do it in the background it needs to run in a different thread. Sometime with bgapi executing the command to do the upload passing the right params should work.<div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Feb 21, 2018, at 2:48 PM, Sonnie <<a href="mailto:basmo13@yahoo.co.uk" class="">basmo13@yahoo.co.uk</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class=""><div style="background-color: rgb(255, 255, 255); font-family: 'lucida console', sans-serif; font-size: 16px;" class=""><div id="yui_3_16_0_ym19_1_1519242447697_2060" class=""><span class=""></span></div><div class=""></div><div id="yui_3_16_0_ym19_1_1519242447697_2061" dir="ltr" class=""> <span style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2730" class="">I'm writing some IVR in Lua and trying to execute some code while the main program continues execution. </span></div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2731" class=""> </div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2732" class="">I've tried </div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2733" class=""> </div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2734" class=""> ...</div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2735" class=""> -- aws is AWS Command Line Interface</div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2736" class=""> io.popen("aws s3 cp " .. s3_src .. " ".. s3_dst)</div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2737" class=""> os.execute("aws s3 cp " .. s3_src .. " ".. s3_dst)</div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2738" class=""> ... -- program execution continues</div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2739" class=""> </div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2740" class=""><br id="yui_3_16_0_ym19_1_1519242447697_2741" class=""></div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2742" class="">Even tried passing it off to a shell script(`s3_upload`)</div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2743" class=""><br id="yui_3_16_0_ym19_1_1519242447697_2744" class=""></div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2745" class=""> os.execute("s3_upload " .. s3_src .." " .. s3_dst)</div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2746" class=""> io.popen("s3_upload " .. s3_src .. " ".. s3_dst)</div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2747" class=""><br id="yui_3_16_0_ym19_1_1519242447697_2748" class=""></div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2749" class="">I've tried </div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2750" class=""><br id="yui_3_16_0_ym19_1_1519242447697_2751" class=""></div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2752" class=""> session:execute("bgsystem","<wbr id="yui_3_16_0_ym19_1_1519242447697_2753" class="">s3_upload " .. s3_src .. " ".. s3_dst )<br id="yui_3_16_0_ym19_1_1519242447697_2754" class=""></div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2755" class=""><br id="yui_3_16_0_ym19_1_1519242447697_2756" class=""></div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2757" class=""><br id="yui_3_16_0_ym19_1_1519242447697_2758" class=""></div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2759" class="">If i use the Lua Interactive shell to run these commands independently, it works.</div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" id="yui_3_16_0_ym19_1_1519242447697_2760" class=""><br id="yui_3_16_0_ym19_1_1519242447697_2761" class=""></div><div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;" dir="ltr" id="yui_3_16_0_ym19_1_1519242447697_2762" class="">would appreciate any assistance.</div></div></div></div></blockquote></div><br class=""></div></body></html>