#Date Created: Jan 8, 2026 #Author Alex Gebben FROM rocker/r-ver:4.5.2 LABEL org.opencontainers.image.authors=agebben@uwyo.edu #Create a sudo user not called root. This avoids permision issues when working with the files created in the docker and saved on a local unix system #RUN useradd -m -s /bin/bash rdocker RUN apt-get update \ && apt-get install -y sudo\ && adduser --disabled-password --gecos '' rdocker \ && adduser rdocker sudo \ && echo '%sudo ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers \ && chmod 777 /usr/local/lib/R/site-library USER rdocker #Install all necessary packages for anaylysis, file manipulation, or for the required R packages to function. RUN sudo apt-get install -y vim curl git && install2.r dplyr renv && rm -rf /tmp/downloaded_packages WORKDIR /R-Code RUN sudo chmod -R 777 /R-Code #Add VIM R IDE to work in the Container, not required. #Packages used for a vim-R IDE. Can be removed if not used #Add vimrc which can be used with vimplug to run an R ide to perform R edits in the terminal. ADD VIM_R_IDE/.vimrc /home/rdocker/.vimrc