.
This commit is contained in:
parent
1553a2132a
commit
53dd9e870d
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
/.ipynb_checkpoints/*
|
||||||
13
Dockerfile
13
Dockerfile
@ -1,11 +1,20 @@
|
|||||||
FROM pytorch/pytorch:latest
|
FROM pytorch/pytorch:latest
|
||||||
|
|
||||||
# Install Jupyter Notebook
|
# Install JupyterLab
|
||||||
RUN pip install jupyterlab
|
RUN pip install jupyterlab
|
||||||
|
|
||||||
# Install additional packages
|
# Install additional packages
|
||||||
RUN pip install tensorflow
|
RUN pip install plotly
|
||||||
|
|
||||||
# Set environment variables, etc.
|
# Set environment variables, etc.
|
||||||
#ENV MY_ENV_VAR=myvalue
|
#ENV MY_ENV_VAR=myvalue
|
||||||
|
|
||||||
|
# Set the working directory
|
||||||
|
WORKDIR /workspace
|
||||||
|
|
||||||
|
# Expose the port for JupyterLab
|
||||||
|
EXPOSE 8888
|
||||||
|
|
||||||
|
# Command to run JupyterLab
|
||||||
|
CMD ["jupyter-lab", "--ip=0.0.0.0", "--port=8888", "--no-browser", "--allow-root", "--NotebookApp.token=''"]
|
||||||
|
|
||||||
|
|||||||
@ -5,16 +5,9 @@ services:
|
|||||||
build: /opt/jupyter_pytorch
|
build: /opt/jupyter_pytorch
|
||||||
container_name: my_build_jupyter
|
container_name: my_build_jupyter
|
||||||
runtime: nvidia
|
runtime: nvidia
|
||||||
deploy:
|
|
||||||
resources:
|
|
||||||
reservations:
|
|
||||||
devices:
|
|
||||||
- capabilities: [gpu]
|
|
||||||
environment:
|
environment:
|
||||||
- JUPYTER_ENABLE_LAB=yes
|
- JUPYTER_ENABLE_LAB=yes
|
||||||
volumes:
|
volumes:
|
||||||
- /opt/jupyter_pytorch/notebooks:/workspace # Map local notebook directory to container
|
- ./notebooks:/workspace
|
||||||
ports:
|
ports:
|
||||||
- "8888:8888" # Expose port 8888 to the host
|
- "8888:8888"
|
||||||
command: >
|
|
||||||
bash -c "jupyter-lab --ip=0.0.0.0 --port=8888 --no-browser --allow-root --NotebookApp.token='' --NotebookApp.password=''"
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user