From afe86d69994278ccf902ddc9075e9a808008ea1c Mon Sep 17 00:00:00 2001 From: Jonathan Felder Date: Tue, 16 Jul 2024 16:10:54 -0700 Subject: [PATCH] [DH-331] make webpdf export work for publichealth --- deployments/publichealth/image/Dockerfile | 5 +++++ deployments/publichealth/image/environment.yml | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/deployments/publichealth/image/Dockerfile b/deployments/publichealth/image/Dockerfile index 5a233b9f9..ded0c4edd 100644 --- a/deployments/publichealth/image/Dockerfile +++ b/deployments/publichealth/image/Dockerfile @@ -37,6 +37,7 @@ RUN apt-get update > /dev/null && \ libatk-bridge2.0-0 \ libgtk-3-0 \ libnss3 \ + libnspr4 \ libxss1 \ fonts-symbola \ gdebi-core \ @@ -62,6 +63,10 @@ RUN mamba env update -p ${CONDA_DIR} -f /tmp/environment.yml && \ COPY infra-requirements.txt /tmp/infra-requirements.txt RUN pip install --no-cache-dir -r /tmp/infra-requirements.txt +# DH-331, very similar to what was done for datahub in DH-164 +ENV PLAYWRIGHT_BROWSERS_PATH ${CONDA_DIR} +RUN playwright install chromium + # Install IRKernel RUN R --quiet -e "install.packages('IRkernel', quiet = TRUE)" && \ R --quiet -e "IRkernel::installspec(prefix='${CONDA_DIR}')" diff --git a/deployments/publichealth/image/environment.yml b/deployments/publichealth/image/environment.yml index 63f3c750d..a6a138564 100644 --- a/deployments/publichealth/image/environment.yml +++ b/deployments/publichealth/image/environment.yml @@ -10,7 +10,7 @@ dependencies: # RStudio support - otter-grader==2.2.7 # for notebook exporting - - nbconvert==7.6.0 + - nbconvert[webpdf]==7.16.4 - nb2pdf==0.6.2 - nbpdfexport==0.2.1 # pulled in by ottr, if not pinned to 1.16.2, 1.16.3 causes DH-323