Skip to content

Commit 104b645

Browse files
authored
Merge pull request #5 from uw-it-aca/pm-RTTL-39-add-rstudio
Pm rttl 39 add rstudio
2 parents d75b6e7 + 81b2403 commit 104b645

File tree

3 files changed

+50
-0
lines changed

3 files changed

+50
-0
lines changed

rstudio/Dockerfile

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
ARG BASE_CONTAINER=jupyter/r-notebook:hub-1.3.0
2+
FROM $BASE_CONTAINER
3+
4+
RUN pip install jupyter-rsession-proxy
5+
RUN conda install -y -c r r-tidyverse
6+
7+
# install rstudio-server
8+
# Note: 1.4x & 1.3x have problems with proxying and auth flow, see: https://github.com/jupyterhub/jupyter-rsession-proxy/issues/97
9+
USER root
10+
RUN apt-get update && \
11+
apt-get install gdebi-core -y && \
12+
curl --silent -L --fail http://security.ubuntu.com/ubuntu/pool/main/o/openssl1.0/libssl1.0.0_1.0.2n-1ubuntu5.6_amd64.deb > /tmp/libssl.deb && \
13+
apt-get install -y /tmp/libssl.deb && \
14+
curl --silent -L --fail https://download2.rstudio.org/server/trusty/amd64/rstudio-server-1.2.5042-amd64.deb > /tmp/rstudio.deb && \
15+
echo 'f6d212f2fdc1e1b4e605256a91b69fed6b61c046374934d262b2c3f1e234c0d6 /tmp/rstudio.deb' | shasum -a 256 -c - && \
16+
apt-get install -y /tmp/rstudio.deb && \
17+
rm /tmp/rstudio.deb && \
18+
rm /tmp/libssl.deb && \
19+
apt-get clean
20+
21+
# These were needed in 1.4x - keeping in case proxy issues are sorted
22+
# RUN rm /var/lib/rstudio-server/rstudio.sqlite && \
23+
# chmod -R 777 /var/lib/rstudio-server
24+
# ENV RSESSION_PROXY_RSTUDIO_1_4=yes
25+
26+
ENV PATH=$PATH:/usr/lib/rstudio-server/bin
27+
28+
USER $NB_USER

rstudio/Makefile

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
APP_BIN?=app
2+
3+
.PHONY: default
4+
default: build
5+
6+
DOCKER_REPO?=gcr.io/uwit-mci-axdd/rttl-rstudio-notebook
7+
DOCKER_TAG?=fdf878c
8+
9+
build:
10+
docker build -t $(DOCKER_REPO):latest -t $(DOCKER_REPO):$(DOCKER_TAG) .
11+
12+
push: build
13+
docker push $(DOCKER_REPO):latest

rstudio/README.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# rttl-notebooks - RStudio
2+
Docker image for RStudio notebook using jupyter-rsession-proxy to handle auth flow with JupyterHub. Note: latest RStudio version that runs correctly is 1.2.5042
3+
4+
Running notebook locally
5+
- `docker run -p 8888:8888 gcr.io/uwit-mci-axdd/rttl-rstudio-notebook:latest`
6+
- Console output will include localhost url with access token. Add '/rstudio' to the end of the path portion
7+
8+
Accessing server shell locally
9+
- `docker run -it --entrypoint /bin/bash gcr.io/uwit-mci-axdd/rttl-rstudio-notebook:latest`

0 commit comments

Comments
 (0)