Deploy R based APIs and web applications at scale with ease using the 1-Click OpenCPU app. Use RStudio Server Open Source as a multi-tenant environment and to interactively develop and deploy applications to the server.

Software Included

Package Version License
OpenCPU 2.2.4 Apache 2
RStudio Server Open Source Edition 1.3.959 AGPL v3
R 4.1.0 GPL-2

Creating an App using the Control Panel

Click the Deploy to DigitalOcean button to create a Droplet based on this 1-Click App. If you aren’t logged in, this link will prompt you to log in with your DigitalOcean account.

Deploy to DO

Creating an App using the API

In addition to creating a Droplet from the OpenCPU 1-Click App using the control panel, you can also use the DigitalOcean API. As an example, to create a 4GB OpenCPU Droplet in the SFO2 region, you can use the following curl command. You need to either save your API access token) to an environment variable or substitute it in the command below.

curl -X POST -H 'Content-Type: application/json' \
         -H 'Authorization: Bearer '$TOKEN'' -d \
        '{"name":"choose_a_name","region":"sfo2","size":"s-2vcpu-4gb","image": "analythium-opencpu-20-04"}' \

Getting Started After Deploying OpenCPU

Use your SSH key you set up with your droplet to log in: ssh -i ~/.ssh/id_rsa root@your_droplet_public_ipv4. Add new user as adduser user_name, optionally make them superuser as usermod -aG sudo user_name.

Go to http://your_host/rstudio and log in using the newly created username and password. Install a demo app via remotes::install_github("rwebapps/appdemo"). Now visit http://your_host/ocpu/user/user_name/library/appdemo/ to see the demo app. Go to http://your_host/ocpu/ to explore and test various endpoints.