Skip to content

Commit 4bcdfee

Browse files
committed
Explicitly prune dependencies to shrink tg
1 parent 5c6665a commit 4bcdfee

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

Dockerfile

+13
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,23 @@ ENV TARGET_DIR=${GITHUB_WORKSPACE:-/github/workspace}
1313
# Build the Jupyter lite web app, the pyodide kernel option is passed for offline availability
1414
# (see https://jupyterlite.readthedocs.io/en/latest/howto/configure/advanced/offline.html), the
1515
# Kernel version is taken from https://github.com/jupyterlite/pyodide-kernel/blob/main/packages/pyodide-kernel/package.json
16+
#
17+
# We need to trim the size of our package down, so we are explicitly deleting some default wheels
18+
# from the resulting output. Hacky!
1619
CMD jupyter lite build \
1720
--config /build/jupyter_lite_config.json \
1821
--lite-dir /build \
1922
--no-sourcemaps \
2023
--output-dir notebooks \
2124
--pyodide https://github.com/pyodide/pyodide/releases/download/0.23.2/pyodide-0.23.2.tar.bz2 \
25+
&& rm notebooks/static/pyodide/astropy-5.2* \
26+
&& rm notebooks/static/pyodide/biopython-1.81* \
27+
&& rm notebooks/static/pyodide/bokeh-3.1* \
28+
&& rm notebooks/static/pyodide/Fiona-1.8* \
29+
&& rm notebooks/static/pyodide/gdal-3.5* \
30+
&& rm notebooks/static/pyodide/mypy-1.1* \
31+
&& rm notebooks/static/pyodide/opencv_python-4.7* \
32+
&& rm notebooks/static/pyodide/RobotRaconteur-0.15* \
33+
&& rm notebooks/static/pyodide/sympy-1.11* \
34+
&& rm notebooks/static/pyodide/yt-4.1* \
2235
&& tar -czf ${TARGET_DIR}/jupyter-lite-build.tgz notebooks

0 commit comments

Comments
 (0)