1.8 KiB
1.8 KiB
docker-jupyterhub
Getting started
构建自己的docker镜像
修改自己想要的python环境在文件Dockerfile.jupyterhub
基础镜像是:jupyter/scipy-notebook 里面含有conda
docker buildx build -t hotwa/jupyterhub:latest . -f Dockerfile.jupyterhub --load
修改docker-compose.yml文件环境变量:DOCKER_NOTEBOOK_IMAGE
DOCKER_NOTEBOOK_IMAGE: hotwa/jupyterhub:latest
也可以通过 docker-compose 构建镜像
docker compose build
启动docker-compose.yml
docker compose up -d
停止
docker compose down
https://github.com/jupyter/docker-stacks/tree/main/images
构建自己的基础镜像:
git clone https://github.com/jupyter/docker-stacks
cd docker-stacks/images/base-notebook
# 修改这个目录下面的 Dockerfile文件, 在后面加就行,里面已经有了mamba、conda
docker buildx build -t hotwa/notebook:latest . -f Dockerfile
Alternatives
- rocker/binder - From the R focused rocker-project, lets you run both RStudio and Jupyter either standalone or in a JupyterHub
- jupyter/repo2docker - Turn git repositories into Jupyter-enabled Docker Images
- openshift/source-to-image - A tool for building artifacts from source code and injecting them into docker images
- jupyter-on-openshift/jupyter-notebooks - OpenShift compatible S2I builder for basic notebook images