RStudio Workbench (previously RStudio Server Pro) requires root privileges for installation and certain operations. Note that root privileges are typically used for system wide installations of R on Linux servers.
sudo yum install R
sudo yum install --nogpgcheck <rstudio-server-package.rpm>
RStudio Workbench runs as the system root user during startup and for creating R sessions on behalf of users.
Further details are explained in the admin guide:
RStudio Workbench runs as the system root user during startup and then drops this privilege and runs as a more restricted user. RStudio Workbench then re-assumes root privilege for a brief instant when creating R sessions on behalf of users (the server needs to call setresuid when creating the R session, and this call requires root privilege).
The user account that RStudio Workbench runs under in the normal course of operations is rstudio-server. This account is automatically added to the system during installation and is created as a system rather than end user account (i.e. the --system flag is passed to useradd).
One way to control the scope of root access is to install RStudio Workbench in a VM or docker. That way root access will be bound to the instance as opposed to the physical server.
See also: access-and-security, Root Requirements for Shiny Server
Comments