EDIT:
In my shiny app, I need to download/image using URL in "www" folder and display the same using renderImage function in the shiny user Interface. Though download.file and write_disk works at R Studio side but as @JorisMeys mentioned these functions must be called on the user side, not the server side. Looking for alternative to write/download images in "www" folder at shiny server end.
I am getting strange issue, When I am running my shiny App from R Studio , I am able to download image from the Url using "download.file" and render the image. But When I am deploying the app in shiny server, the image is not getting downloaded. Getting clueless, looking for suggestions to resolve this issue. Just to clarify its not that "download.file" is not downloading the Image.Its working for the shiny App when opened through R Studio but not from from Shiny Server Side. As suggested in this link - how to download and display an image from an URL in R?
Code which has been used:
filename <- imagename.jpg
downloadURL<-http://username:password@dev:9090/project_name/fileContents/imagepath/imagename.jpg #URL format
download.file(URLencode(downloadURL),paste(getwd(),"/www", "/", filename, sep = ""),quiet = TRUE)