Skip to content

Commit

Permalink
use /opt/venv
Browse files Browse the repository at this point in the history
  • Loading branch information
cboettig committed Nov 27, 2023
1 parent e2f4d94 commit c2c006d
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,20 +1,30 @@
# devcontainer-focused Rocker
FROM ghcr.io/rocker-org/devcontainer/tidyverse:4.3


ENV NB_USER=rstudio
ENV VIRTUAL_ENV=/opt/venv
ENV PATH=${PATH}:${VIRTUAL_ENV}/bin
ADD https://raw.githubusercontent.com/rocker-org/rocker-versioned2/c1a472465532c8349cf0ad4f3f95c86e85787dc3/scripts/install_python.sh install_python.sh
RUN bash install_python.sh && rm install_python.sh


RUN apt-get update && apt-get -y install libxt6
RUN /rocker_scripts/install_python.sh
ADD https://raw.githubusercontent.com/rocker-org/rocker-versioned2/master/scripts/experimental/install_dev_osgeo.sh install_dev_osgeo.sh
RUN bash install_dev_osgeo.sh && rm install_dev_osgeo.sh

RUN chown -R rstudio:rstudio /opt/venv

USER rstudio
WORKDIR /home/rstudio
RUN usermod -s /bin/bash rstudio

COPY requirements.txt requirements.txt
ENV PATH=$PATH:/home/rstudio/.local/bin

RUN pip install --user -r requirements.txt && rm requirements.txt
RUN python -m pip install -r requirements.txt && rm requirements.txt
COPY install.R install.R
RUN Rscript install.R && rm install.R

# some teaching preferences
RUN git config --global pull.rebase false
RUN git config --global pull.rebase false

0 comments on commit c2c006d

Please sign in to comment.