diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..3141590 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/.ipynb_checkpoints/* diff --git a/Dockerfile b/Dockerfile index 2b48440..c85fec6 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,11 +1,20 @@ FROM pytorch/pytorch:latest -# Install Jupyter Notebook +# Install JupyterLab RUN pip install jupyterlab # Install additional packages -RUN pip install tensorflow +RUN pip install plotly # Set environment variables, etc. #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=''"] + diff --git a/my_build.docker-compose.yml b/my_build.docker-compose.yml index 834ba88..9b3f0d4 100644 --- a/my_build.docker-compose.yml +++ b/my_build.docker-compose.yml @@ -5,16 +5,9 @@ services: build: /opt/jupyter_pytorch container_name: my_build_jupyter runtime: nvidia - deploy: - resources: - reservations: - devices: - - capabilities: [gpu] environment: - JUPYTER_ENABLE_LAB=yes volumes: - - /opt/jupyter_pytorch/notebooks:/workspace # Map local notebook directory to container + - ./notebooks:/workspace ports: - - "8888:8888" # Expose port 8888 to the host - command: > - bash -c "jupyter-lab --ip=0.0.0.0 --port=8888 --no-browser --allow-root --NotebookApp.token='' --NotebookApp.password=''" + - "8888:8888"