Base Jupyter Notebook for Apple
1.5K
Dockerfiles and related assets for IllumiDesk's workspace images for the Apple.
Everything from the jupyter/datascience-notebook plus PyTorch.
make venv
make build-all
Running the image standalone is helpful for testing:
docker run -p 8888:8888 illumidesk/apple-notebook:latest
Then, navigate to http://localhost:8888 to access your Jupyter Notebook server.
Refer to docker's documentation for additional
docker run ...options.
make test
TAG argument to add your custom tag. The TAG argument defaults to python-3.9.5 if not specified.Build all images:
make build-all
Build one image with custom tag:
make build/apple-notebook TAG=mytag
FROM jupyter/scipy-notebook:python-3.9.5
RUN ... do stuff
# make sure you run fix-permissions after doing stuff
USER root
RUN fix-permissions "${HOME} \
&& fix-permissions "${CONDA_DIR}
USER "${NB_USER}"
If you would like to use an organization other than IllumiDesk's, then step requires creating an Organization account in DockerHub or other docker image compatible registry. The docker push ... command will push the image to the DockerHub registry by default. Please refer to the official Docker documentation if you would like to push another registry.
For example:
docker push illumidesk/apple-notebook:python-3.9.5
make venv
make lint-all
make build-all
make test
There are two ways to add additional dependencies:
spec-list.txt file with conda/pip dependenciesSimilar to Python's requirements.txt, the spec-list.txt locks a dependency tree. The difference is that the spec-list.txt combines both conda and pip dependencies.
After you have updated the dependencies in your docker image update the spec-list.txt file with the following the steps below:
docker run -it --rm -v $(pwd):/tmp illumidesk/apple-notebook:<your-tag> /bin/bash
... steps to install conda/pip packages ...
conda list --explicit > /tmp/apple-notebook/spec-list.txt
Note: replace
<your-tag>with the tag you used to build the image. The default value is located in theMakefileif using themakecommand or theFROMdirective in the Dockerfile if using the nativedocker build ...command.
Update the Dockerfile(s) with additional dependencies
Build the docker image with custom arguments (ARGS):
Use the --build-args flag with the docker build command to override the arguments included in the Dockerfile. For example, if you would like to build/test an image with a different version of Apache Spark (let's assume version 1.2.3) then build the image like so:
docker build --build-args spark_version=1.2.3 illumidesk/apple-notebook:mytag apple-notebook/.
Or
make DARGS="--build-args spark_version=1.2.3" build/apple-notebook
There are two environments configured with this repo:
main branchproduction branchDevelopment and production versions are built with the DockerHub build actions located in the illumidesk/apple-grader and the illumidesk/apple-notebook for the grader and end-user notebooks, respectively.
The steps below are applicable to both the main and production branches.
Fork option.$ git clone `https://github.com/<github-account>/apple-stacks.git`
NOTE: Replace the
<apple-account>placeholder above with your GitHub username.
git remote add upstream https://github.com/illumidesk/apple-stacks.git
git remote -v
The command above should return an output similar to:
origin https://github.com/foobar/apple-stacks (fetch)
origin https://github.com/foobar/apple-stacks (push)
upstream https://github.com/illumidesk/apple-stacks (fetch)
upstream https://github.com/illumidesk/apple-stacks (push)
$ make dev
$ source venv/bin/activate
or
$ virtualenv -p python3 venv
$ python3 -m pip install -r dev-requirements.txt
$ source venv/bin/activate
$ git checkout -b branch-name-here
Make the appropriate changes for the issue you are trying to address. Build and test the image(s) as instructed in the Build and Test section above. Please note that these are very basic validations. It is recommended to run tests with actual Jupyter Notebook (*.ipynb) files.
Add and commit the changed files:
git add .
git commit -m "my commit message here"
$ git push origin <branch-name-here>
Updates instead of Updated or Updating.main or production branch.main will trigger a build with DockerHub with the dev tag. Merges to production will create a build with the prod tag.Logout button in the Notebook interface.#apple Slack channel. If you do not have access to this channel then you may request support by visiting https://support.illumidesk.com to chat with a customer support agent.These images are based on the jupyter/docker-stacks images. Refer to their documentation for the full set of configuration options.
MIT
Content type
Image
Digest
Size
2.4 GB
Last updated
over 4 years ago
docker pull illumidesk/apple-notebook