How can I use an {golem} app in a shiny-server?

Hy, guys!

I tried to put an shiny app create with {golem} in an AWS shiny-server.

The Shiny-Server is correctly installed, because when I use a conventional application (without using the golem), it works. That is, an application with the ui.R, server.R and globals.R files runs normally on the server.

I will list the steps I followed below:

  • I put the package folder inside: srv > shiny-server > mypackagedapp

  • I inserted the app.R file in with golem::add_shinyappsio_file() and golem::add_shinyserver_file()

  • I processed http://192.xxx.x.xxx/mypackagedapp in the browser, just like I did for the conventional application, which works perfectly.

However, the following message appears: An error has occurred. The application failed to start. The application exited during initialization.

What am I missing? I tried to read here, but I'm still failing.

If you are deploying to shiny server, you should only use golem::add_shinyserver_file() not golem::add_shinyappsio_file().

Can you show your app's logs? That would give us a better picture of what is going on. You can find them here

/var/log/shiny-server/