By: Peter Solymos

Originally published at Hosting Data Apps blog on 2021–06–14.

This post picks up where we left off with hosting Shiny apps with Docker run and Caddy server. There were a few shortcomings with that very basic setup: the home page looked very blunt, and managing updates to the apps was not at all streamlined.

In this post, you will learn how to use Docker Compose to simplify the management of deploying and updating multiple Shiny apps and a proxy server. …


By: Peter Solymos

Originally published at Hosting Data Apps blog on 2021–06–07.

We looked at best practices for R with Docker where we compared four commonly used parent images. It was common in these images that these all contained a “local” Shiny app using . A special breed of dockerized Shiny apps is when the Shiny Server is running inside the Docker container. In this post, we'll explore this "dockerized Shiny Server" setup and discuss the pros and cons.

The files from this post can be found in the analythium/covidapp-shiny GitHub repository, inside the folder.

The Dockerfile

The parent image of…


By: Peter Solymos

Originally published at Hosting Data Apps blog on 2021–06–03.

Photo by Sieuwert Otterloo on Unsplash

Lots of resources describe how you can host Shiny apps with Docker, Shiny Server, or via other means. But we also know Shiny apps can be launched locally. What makes your local setup different from these other options is that your local machine does not usually have a static internet protocol (IPv4) address. Without a static IPv4, it is really hard to share the app with other people because the address keeps changing unpredictably, and you might sometimes power off your machine.

Shiny uses the httpuv R package…


By: Peter Solymos

Originally published at Hosting Data Apps blog on 2021–05–31.

Photo by moren hsu on Unsplash

You learned about Shiny, Docker, how to dockerize Shiny apps, and how to manage dependencies. But why dockerize Shiny apps in the first place? Let’s see what Shiny and Docker have in common. Shiny “makes it easy to build interactive web apps straight from R”, while Docker is the “de facto standard to build and share containerized apps — from desktop, to the cloud. Their intersection is the web and web applications belong to the web.

This post walks you through a very basic setup on your own…


By: Peter Solymos

Originally published at Hosting Data Apps blog on 2021–05–27.

The use of Docker with R has been transformative in many ways over the past 5 years. What is common in this diversity of use cases is that the Docker images almost always start with a parent image. What parent image you use? How do you add new layers to it? These questions will determine how quickly you can iterate while in development, and the size of the final image you send to production. In this post, I will compare using different parent images and outline best practices…


By: Peter Solymos

Originally published at Hosting Data Apps blog on 2021–05–24.

Shiny Server is a free and open-source option for self hosting Shiny apps and it is one of the 3 options listed on the Shiny website. In a previous post you saw how to secure Shiny Server with a custom domain. Here you will lear how to add and update Shiny apps to your server.

Follow the instructions from the previous post or spin up a brand new virtual machine on DigitalOcean using the RStudio 1-click app in minutes.

The file for the Shiny Server's landing page…


By: Peter Solymos

Originally published at Hosting Data Apps blog on 2021–05–20.

Shiny Server is a free and open-source option for self hosting Shiny apps. The Shiny Server is one of the 3 options listed on RStudio’s official Shiny documentation. The paid Shiny Server Pro version is discontinued in favour of RStudio Connect.

Hosting Shiny apps on the open source Shiny Server requires to (1) set up a virtual machine (VM) with one of the public cloud providers; (2) install R, required packages, and Shiny Server on the VM; and (3) copy your Shiny application to the Shiny Server VM.


By: Peter Solymos

Originally published at Hosting Data Apps blog on 2021–05–17.

What makes programming languages like R and Python great for making data applications is the wealth of contributed extension packages that supercharge app development. You can turn your code into an interactive web app with not much extra code once you have a workflow and an interesting question.

We have reviewed Docker basics and how to dockerize a very simple Shiny app. For anything that is a little bit more complex, you will have to manage dependencies. Dependency management is one of the most important aspects of app…


By: Peter Solymos

Originally published at Hosting Data Apps blog on 2021–05–13.

Image from Unsplash

In a previous post you saw how to run Shiny apps locally. Certain use cases need to be run locally, most web applications deserve to be hosted on the web. The official Shiny documentation on the RStudio website offers 3 ways of putting Shiny applications on the web:

  1. Shinyapps.io: free or paid cloud hosting with push button publishing
  2. RStudio Connect: paid self hosted option for authoring Shiny apps among many other things with push button or git based publishing
  3. Shiny Server: free self hosted option with file transfer…

By: Peter Solymos

Originally published at Hosting Data Apps blog on 2021–05–07.

All the general advantages of containerized applications apply to Shiny apps. Docker provides isolation to applications. Images are immutable: once build it cannot be changes, and if the app is working, it will work the same in the future. Another important consideration is scaling. Shiny apps are single threaded, but running multiple instances of the same image can serve many users at the same time. Let’s dive into the details of how to achieve this.

This post is based on the analythium/shinyproxy-hello GitLab project. Readt about the Shiny…

Péter Sólymos

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store