From 44758b9e6ddb68ca8a55b8060ba4f261a775309d Mon Sep 17 00:00:00 2001 From: CJ Yetman Date: Fri, 9 Feb 2024 12:57:41 +0100 Subject: [PATCH] determine and install dependencies with {pak} (#97) closes #96 --- Dockerfile | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index fbeabb1..905d17f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ FROM --platform=linux/amd64 rocker/tidyverse -RUN Rscript -e 'install.packages(c("pak", "renv"))' +RUN Rscript -e 'install.packages("pak")' COPY . /workflow.data.preparation @@ -8,9 +8,7 @@ WORKDIR /workflow.data.preparation RUN Rscript -e '\ readRenviron(".env"); \ - non_cran_pkg_deps <- c("RMI-PACTA/pacta.scenario.preparation", "RMI-PACTA/pacta.data.preparation", "RMI-PACTA/pacta.data.scraping"); \ - cran_pkg_deps <- setdiff(renv::dependencies()$Package, basename(non_cran_pkg_deps)); \ - pak::pkg_install(pkg = c(non_cran_pkg_deps, cran_pkg_deps)); \ + pak::local_install_deps(); \ ' CMD Rscript run_pacta_data_preparation.R