Running RStudio on Digital Ocean, AWS etc Using Tutum and Docker Containers

Via RBloggers I noticed a tutorial today on Setting Rstudio server using Amazon Web Services (AWS).

In the post Getting Started With Personal App Containers in the Cloud I described how I linked my tutum account to a Digital Ocean hosting account and then launched a Digital Ocean server. (How to link tutum to Amazon AWS is described here: tutum support: Link your Amazon Web Services account.)

Having launched a server (also described in Getting Started With Personal App Containers in the Cloud), we can now create a new service that will fire up an RStudio container.

First up, we need to locate a likely container – the official one is the rocker/rstudio image:

New_Service_Wizard___Tutum

Having selected the image, we need to do a little bit of essential configuration (we could do more, like giving the service a new name):

New_Service_Wizard___Tutum2

Specifically, we need to publish the port so that it’s publicly viewable – then we can Create and Deploy the service:

New_Service_Wizard___Tutum3

After a minute or two, the service should be up and running:

rstudio-8a316887___Tutum4

We can now find the endpoint, and click through to it (note: we need to change the URL from a tcp:// address to an http:// one. (Am I doing something wrong in the set up to stop the http URL being minted as the service endpoint?)

rstudio-8a316887___Tutum5

URL tweaked, you should now be able to see an RStudio login screen. The default user is rstudio and the default password rstudio too:

RStudio_Sign_In

And there we have it:-)

RStudio

So we don’t continue paying for the server, I generally stop the container and then terminate it to destroy it…

rstudio-8a316887___Tutum

And then terminate the node…

Node_dashboard___Tutum5

So, assuming the Amazon sign-up process is painless, I’m assuming it shouldn’t be much harder than that?

By the by, it’s possible to link containers to other containers; here’s an example (on the desktop, using boot2docker, that links an RStudio container to a MySQL database: Connecting RStudio and MySQL Docker Containers – an example using the ergast db. When I get a chance, I’ll have a go at doing that via tutum too…

PS see also: How to Run An R Shiny App in the Cloud Using Tutum, Digital Ocean and Docker Containers.

Author: Tony Hirst

I'm a Senior Lecturer at The Open University, with an interest in #opendata policy and practice, as well as general web tinkering...

4 thoughts on “Running RStudio on Digital Ocean, AWS etc Using Tutum and Docker Containers”

  1. where the instruction is –
    “note: we need to change the URL from a tcp:// address to an http:// one.”
    Can you explain how this is done?
    I cannot find a way to change tcp to anything other than udp in the settings.

    1. @alistairwalsh I can’t find how to do it in the tutum control panel, so the fix is a purely manual one: just copy the link, delete tc and replace it with htt !;-)

    1. What page are you trying to connect to? If you’re trying to connect to the links that my setup generated, they won’t be there any more; I killed the machine as soon as I was done with it (they’re metered….)

Comments are closed.