FROM rocker/r-ver:latest

RUN apt-get update -y
RUN apt-get install -y apt-utils
RUN apt-get install -y libxml2 xml2
RUN apt-get install -y libxml2-dev
RUN apt-get install -y libcurl4-openssl-dev libssh2-1-dev libssl-dev git
RUN apt-get install -y qpdf pandoc pandoc-citeproc openssh-client curl
RUN apt-cache search git
RUN apt-get install -y libgit2-dev

RUN R -e 'install.packages(c("roxygen2"), repos="http://cran.rstudio.com")'
RUN R -e 'install.packages(c("git2r","usethis","devtools","testthat"), repos="http://cran.rstudio.com")'
RUN R -e 'install.packages(c("R6","rhoR","cli"), repos="http://cran.rstudio.com")'

### Steps needed for testing the package and storing files
RUN R -e 'install.packages(c("covr", "DT"), repos="http://cran.rstudio.com")'
RUN R -e 'install.packages(c("aws.s3","aws.signature"), repos="http://cran.rstudio.com")'
RUN R -e 'install.packages(c("fs"), repos="http://cran.rstudio.com")'
RUN R -e 'install.packages(c("pkgdown"), repos="http://cran.rstudio.com")'
RUN R -e 'install.packages(c("aws.s3","aws.signature"), repos="http://cran.rstudio.com")'

RUN R --version
