| FROM python:3.11-slim |
|
|
| RUN apt-get update && apt-get install -y \ |
| git \ |
| && rm -rf /var/lib/apt/lists/* |
|
|
| RUN pip install --no-cache-dir jupyterlab jupyter-server |
|
|
| ENV PORT=7860 |
| ENV JUPYTER_PASSWORD=changeme |
|
|
| WORKDIR /workspace |
|
|
| CMD ["sh", "-c", "\ |
| HASHED_PASSWORD=$(python - << 'EOF'\nfrom jupyter_server.auth import passwd\nimport os\nprint(passwd(os.environ['JUPYTER_PASSWORD']))\nEOF\n) && \ |
| jupyter lab \ |
| --ip=0.0.0.0 \ |
| --port=7860 \ |
| --no-browser \ |
| --IdentityProvider.token='' \ |
| --PasswordIdentityProvider.hashed_password=$HASHED_PASSWORD \ |
| "] |
|
|