This repository contains a Jupyterlite build and some example Jupyter notebooks to be used within Quepid. The build is offline-optimized to be used in environments with no access to the public internet. It prepackages the Pyodide kernel and all dependencies according Jupyterlite manual.
- The build is Docker based. For a local run try
docker run -it --rm -e TARGET_DIR=/dist -v "$(pwd)":/dist $(docker build -q .)
. This will generate ajupyter-lite-build.tgz
with the self-contained Jupyterlite web app in your current directory. - On Github a GH action uses the Docker build and is embedded into the build workflow which also add the build artifact as a release asset.
- To create a new release push a new tag. Then the job will fire.
- Check requirements.txt and jupyter_lite_config.json for library updates
- Check Dockerfile for Pyodide updates
Unzip the TGZ file which will then unpack into ./notebooks
.
Run either python -m http.server 8000 --directory ./notebooks
or ruby -run -ehttpd ./notebooks -p 8000
Browse to http://localhost:8000 and you should see the Jupyterlite interface.
- Run
docker run -it --rm -e TARGET_DIR=/dist -v "$(pwd)":/dist $(docker build -q .)
producing the jupyter-lite-build.tgz. - Unzip it into the ./notebooks
rm -rf public/notebooks
in Quepid- Make sure Quepid's docker-compose.override.yml has a line similar to
- /Users/epugh/Documents/projects/quepid-jupyterlite/notebooks:/srv/app/public/notebooks
1.bin/docker s
for Quepid - In your Browser developer tools under network click "Disable Cache".
- Now load the content: http://localhost:3000/notebooks
- Make changes,
- Do a fresh kernal restart and rerun, the
>>
button. - Update the footer date stamp.
- then download and save the file in
./jupyterlite/files
tree. - Delete
jupyterlite.tar.gz
- run
docker run -it --rm -e TARGET_DIR=/dist -v "$(pwd)":/dist $(docker build -q .)