Unable to create new shiny web app in RSTUDIO on CENTOS7 platform

I have installed R, RSTUDIO server and SHINY server in root on CENTOS7. Then I created a user and gave it admin power (sudo user). And then I assigned ownership of /srv/shiny-server to this sudo user. But still when I am opening studio server on the browser on the same machine and other machines as well... It is not allowed to make new shiny web app.Error shown is : permission denied.

How can this problem be resolved?

My understanding of how Shiny Server works is that your apps are run by default as a user called shiny. This means the shiny user on your server needs to be able to read the files. Even though you gave permission to write to /srv/shiny-server, you still need the change permissions so shiny can read them.

The simplest solution is to use chmod to grant permissions to the files and folder. You can use something like this:

Chmod 777 -R /srv/shiny-server/appname

Keep in mind you need to run that command as either root or as the user who created the files.