diff --git a/deployments/data8/image/apt.txt b/deployments/data8/image/apt.txt index e9646bf15..37e4c7a7c 100644 --- a/deployments/data8/image/apt.txt +++ b/deployments/data8/image/apt.txt @@ -77,3 +77,7 @@ meld # For jupyter-tree-download. Ref: https://github.com/berkeley-dsep-infra/datahub/issues/3979 zip + +# playwright deps https://jira-secure.berkeley.edu/browse/DH-325 +libnss3 +libnspr4 diff --git a/deployments/data8/image/environment.yml b/deployments/data8/image/environment.yml index 6d57b52ab..ad3b5a542 100644 --- a/deployments/data8/image/environment.yml +++ b/deployments/data8/image/environment.yml @@ -37,9 +37,10 @@ dependencies: #- -r infra-requirements.txt - jupyter-tree-download==1.0.1 # Export notebooks as PDFs with Chrome - - nbconvert==7.6.0 - nb2pdf==0.6.2 - nbpdfexport==0.2.1 +# Enable webpdf export DH-325 + - nbconvert[webpdf]==7.16.4 # Conda only has 0.12.0 - okpy==1.18.1 - git+https://github.com/shaneknapp/python-popularity-contest.git@add-error-handling diff --git a/deployments/data8/image/postBuild b/deployments/data8/image/postBuild new file mode 100644 index 000000000..1b6bcc9d1 --- /dev/null +++ b/deployments/data8/image/postBuild @@ -0,0 +1,5 @@ +#!/usr/bin/env bash + +# installing chromium browser to enable webpdf conversion using nbconvert +export PLAYWRIGHT_BROWSERS_PATH=${CONDA_DIR} +playwright install chromium diff --git a/deployments/data8/image/start b/deployments/data8/image/start new file mode 100644 index 000000000..c3a978b7f --- /dev/null +++ b/deployments/data8/image/start @@ -0,0 +1,5 @@ +#!/bin/bash + +# See https://jira-secure.berkeley.edu/browse/DH-305 +export PLAYWRIGHT_BROWSERS_PATH=${CONDA_DIR} +exec "$@"