-
Notifications
You must be signed in to change notification settings - Fork 86
/
Dockerfile
22 lines (19 loc) · 832 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# get the base image, the rocker/verse has R, RStudio and pandoc
FROM rocker/{{{rocker}}}:{{{r_version}}}
# required
MAINTAINER {{{maintainer}}}
COPY . /{{{repo}}}
# go into the repo directory
RUN . /etc/environment \
# Install linux depedendencies here
# e.g. need this for ggforce::geom_sina
&& sudo apt-get update \
&& sudo apt-get install libudunits2-dev -y \
# build this compendium package
&& R -e "install.packages('remotes', repos = c(CRAN = 'https://cloud.r-project.org'))" \
&& R -e "remotes::install_github(c('rstudio/renv', 'quarto-dev/quarto-r'))" \
# install pkgs we need
&& R -e "renv::restore()" \
# render the manuscript into a docx, you'll need to edit this if you've
# customised the location and name of your main qmd file
&& R -e "quarto::quarto_render('/{{{repo}}}/{{{qmd_path}}}')"