Skip to content

Commit 14d866a

Browse files
authored
Update R kernel installation, remove dependency on r studio CDN (#140)
* update r kernel installation, remove dependency on rstudio cdn * remove unnecessary env vars * fixed env syntax
1 parent 4cdc762 commit 14d866a

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

template/Dockerfile

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
FROM python:3.12
22

33
RUN DEBIAN_FRONTEND=noninteractive apt-get update && apt-get install -y --no-install-recommends \
4-
build-essential curl git util-linux jq sudo fonts-noto-cjk
4+
build-essential curl git util-linux jq sudo fonts-noto-cjk r-base
55

66
# Install Node.js 20.x from NodeSource
77
RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - && \
@@ -13,17 +13,13 @@ ENV PIP_DEFAULT_TIMEOUT=100 \
1313
JUPYTER_CONFIG_PATH="/root/.jupyter" \
1414
IPYTHON_CONFIG_PATH="/root/.ipython" \
1515
SERVER_PATH="/root/.server" \
16-
R_VERSION=4.4.2
17-
18-
ENV R_HOME=/opt/R/${R_VERSION} \
19-
JAVA_HOME=/opt/java/openjdk
16+
JAVA_HOME=/opt/java/openjdk
2017

2118
# Install Jupyter
2219
COPY ./requirements.txt requirements.txt
2320
RUN pip install --no-cache-dir -r requirements.txt && ipython kernel install --name "python3" --user
2421

2522
# R Kernel
26-
RUN curl -O https://cdn.rstudio.com/r/debian-12/pkgs/r-${R_VERSION}_1_amd64.deb && sudo apt-get update && sudo apt-get install -y ./r-${R_VERSION}_1_amd64.deb && ln -s ${R_HOME}/bin/R /usr/bin/R
2723
RUN R -e "install.packages('IRkernel', repos='https://cloud.r-project.org')"
2824
RUN R -e "IRkernel::installspec(user = FALSE, name = 'r', displayname = 'R')"
2925

0 commit comments

Comments
 (0)