too many files error

Whwn deploy R shiny app I receive an error in rsconnect max bundle files
how Can I fix this error?
Where I can modify max number of files?

1 Like

Besides finding a workaround for the maximum number of files I recommend two alternative workarounds (and some best practices):

  1. Create a package to house the application and deploy a single app.R that simply uses the package.

  2. An alternative is to simply "compile" (not really compilation, more of consolidation) in your deployment pipeline / script. You could, for example, compile all "external" R source code files into a single file to be sourced, merge ui.R, server.R, global.R, etc. into one app.R script, etc. Along with ensuring certain unnecessary files are not included in the bundle, cleanup any derived files, etc. This is more oriented towards a mixture of compilation and minification (i.e. C# or C++ and JavaScript/CSS). The idea here is to think in terms of "building" the deployment package and making it as small, performant, and flexible as possible to avoid having to upload a bunch of junk that has to be compressed and in turn decompressed and built on the remote server.

Thanks, I'll try right away. I ask you one more thing. The main R file calls multiple R files. I also read in a data file selected from over 10,000 files. How can I get all the files divided into folders to shinyapps cloud?