ShinyProxy

Deploy interactive R Shiny applications at scale with ease using the 1-Click ShinyProxy app. ShinyProxy builds on enterprise Java and Docker technology to provide authentication, authorization, resource allocation, and monitoring.

Software Included

Package Version License
ShinyProxy 3.1.0 Apache 2
OpenJDK 11.0.22 GPL 2 with the Classpath Exception
Docker CE 24.0.5 Apache 2
Docker Compose 1.29.2 Apache 2
Nginx 1.18.0 2-clause BSD
Certbot 2.10.0 Apache 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 ShinyProxy 1-Click App using the control panel, you can also use the DigitalOcean API. As an example, to create a 4GB ShinyProxy 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-shinyproxy-20-04"}' \
        "https://api.digitalocean.com/v2/droplets"

Getting Started After Deploying ShinyProxy

Log in using ShinyProxy UI

Once your new droplet with the ShinyProxy 1-Click app is up and running, you can visit your droplet’s IP address. Use admin/password or user/password as user name and password to log into your ShinyProxy instance. You’ll see two demo R Shiny applications. Note that it might take 30-60 seconds for all systems to come online: please reload the page if you see an 502 Bad Gateway message from Nginx.

Log in through SSH

Use your SSH key you set up with your droplet to log in: ssh root@your_droplet_public_ipv4.

On the 1st SSH login you will be prompted to set up SSL certificate via Let’s Encrypt to serve the ShinyProxy over HTTPS. You’ll need a domain name with a DNS A record pointing to the Droplet IP address, and an email address.

Edit /etc/shinyproxy/application.yml to configure your instance. Pay special attention to authentication: it is set to simple. You should change user names and passwords, possibly the authentication type.

Pull Docker images and add those to the configuration file to deploy your Shiny apps.

Then restart ShinyProxy to take effect using sudo service shinyproxy restart.

Advanced configuration

Follow the 1-Click App documentation to manually set up SSL certificate to serve the Shiny apps over HTTPS, update the ShinyProxy apps and configs, and to configure continuous integration and continuous delivery (CI/CD) via webhook.