I followed the steps described in the Rstudio blog for generating downloadable reports:
It works fine when runnning locally (RStudio on a computer should it be on linux or windows) or when running on shinyapps.io.
However, when running on a shiny server (linux), the step of copying the .Rmd file into a local copy doesn't work and I don't know why.
tempReport <- file.path(tempdir(), "report.Rmd")
file.copy("report.Rmd", tempReport, overwrite = TRUE)
I get these warnings instead:
Warning in normalizePath(path, winslash = winslash, mustWork = mustWork) :
path="/tmp/RtmpFQ0udh/PSUR_5_2.Rmd": No such file or directory
Warning: Error in tools::file_path_as_absolute: file '/tmp/RtmpFQ0udh/PSUR_5_2.Rmd' does not exist
[No stack trace available]