Run exe file through Shinyapps.io

113 views
Skip to first unread message

ali davari

unread,
Jul 23, 2018, 1:50:36 PM7/23/18
to shinyapps.io Users
First I start with my goal: I have an exe file which gets a data file, then does some computations and return an output files. I want to use R Shiny to get the input data from users, and then run the exe file and finally plot the results.

I used system() command and was able to get input from user and run the exe file, when I execute it locally on my PC. But, when I publish it online (in my Shinyapps.io account) it does not work. I checked the log in my account and got this msg:

sh: 1: foo.exe: not found Warning in system("foo.exe") : error in running command

Is there a solution for what I am trying to do?

Thank you.

Joshua Spiewak

unread,
Jul 23, 2018, 2:01:10 PM7/23/18
to shinyapps.io Users
shinyapps.io is a Linux environment, an exe file cannot run there.

That said, the fact that it couldn't be found might be due to it not being included in the bundle when deploying the application, Make sure all the files you want deployed are checked when you are prompted with the dialog when hitting the Publish button.

ali davari

unread,
Jul 23, 2018, 3:01:21 PM7/23/18
to shinyapps.io Users
Thank you Joshua. I read this online, but is there any solution to this situation? For example, can I compile my Fortran source codes on linux, include all of them in the bundle and then run the compiled Fortran codes in R Shiny?

Joshua Spiewak

unread,
Jul 23, 2018, 5:42:17 PM7/23/18
to shinyapps.io Users
You could attempt that, but without any official support.
Perhaps look into encapsulating your code as an R package so that it will be compiled appropriately for whatever platform it is used on?
Reply all
Reply to author
Forward
0 new messages