From c65ed5e6f3fcc00dad1b48b51330efb8d6924da0 Mon Sep 17 00:00:00 2001 From: Ivan Chvets Date: Wed, 4 Oct 2023 15:00:13 -0400 Subject: [PATCH 1/3] fix: update command and env variables https://github.com/canonical/kubeflow-rocks/issues/54 Summary of changes: - Updated environments in all Jupyter notebook server ROCKs to omit envirtonmen variables that need to be set in the Pod environment. Added comment indicating this. - Updated command to expand environment variables. --- jupyter-pytorch-cuda-full/rockcraft.yaml | 7 ++++--- jupyter-pytorch-full/rockcraft.yaml | 7 ++++--- jupyter-scipy/rockcraft.yaml | 7 ++++--- jupyter-tensorflow-cuda-full/rockcraft.yaml | 9 +++++---- jupyter-tensorflow-full/rockcraft.yaml | 7 ++++--- 5 files changed, 21 insertions(+), 16 deletions(-) diff --git a/jupyter-pytorch-cuda-full/rockcraft.yaml b/jupyter-pytorch-cuda-full/rockcraft.yaml index c05dd9d..94b4cb2 100644 --- a/jupyter-pytorch-cuda-full/rockcraft.yaml +++ b/jupyter-pytorch-cuda-full/rockcraft.yaml @@ -19,8 +19,9 @@ services: environment: NB_USER: jovyan NB_UID: 1001 - NB_PREFIX: / - HOME: /home/jovyan + # the following environment variables need to be present in the Pod environment + #HOME: "" + #NB_PREFIX: "" SHELL: /bin/bash LANG: en_US.UTF-8 LANGUAGE: en_US.UTF-8 @@ -30,7 +31,7 @@ services: NVIDIA_DRIVER_CAPABILITIES: compute,utility LD_LIBRARY_PATH: /usr/local/nvidia/lib:/usr/local/nvidia/lib64 PYTHONPATH: /opt/conda/lib/python3.8/site-packages/ - command: ./jupyter lab --notebook-dir="/home/jovyan" --ip=0.0.0.0 --no-browser --allow-root --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url="/" --ServerApp.authenticate_prometheus=False + command: bash -c './jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' working-dir: /opt/conda/bin/ platforms: amd64: diff --git a/jupyter-pytorch-full/rockcraft.yaml b/jupyter-pytorch-full/rockcraft.yaml index 2a737f4..bf41594 100644 --- a/jupyter-pytorch-full/rockcraft.yaml +++ b/jupyter-pytorch-full/rockcraft.yaml @@ -19,15 +19,16 @@ services: environment: NB_USER: jovyan NB_UID: 1001 - NB_PREFIX: / - HOME: /home/jovyan + # the following environment variables need to be present in the Pod environment + #HOME: "" + #NB_PREFIX: "" SHELL: /bin/bash LANG: en_US.UTF-8 LANGUAGE: en_US.UTF-8 LC_ALL: en_US.UTF-8 PATH: /opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin PYTHONPATH: /opt/conda/lib/python3.8/site-packages/ - command: ./jupyter lab --notebook-dir="/home/jovyan" --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url="/" --ServerApp.authenticate_prometheus="False" + command: bash -c './jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' working-dir: /opt/conda/bin/ platforms: amd64: diff --git a/jupyter-scipy/rockcraft.yaml b/jupyter-scipy/rockcraft.yaml index 22f170a..ba9dc3c 100644 --- a/jupyter-scipy/rockcraft.yaml +++ b/jupyter-scipy/rockcraft.yaml @@ -19,15 +19,16 @@ services: environment: NB_USER: jovyan NB_UID: 1001 - NB_PREFIX: / - HOME: /home/jovyan + # the following environment variables need to be present in the Pod environment + #HOME: "" + #NB_PREFIX: "" SHELL: /bin/bash LANG: en_US.UTF-8 LANGUAGE: en_US.UTF-8 LC_ALL: en_US.UTF-8 PATH: /opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin PYTHONPATH: /opt/conda/lib/python3.8/site-packages/ - command: ./jupyter lab --notebook-dir="/home/jovyan" --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url="/" --ServerApp.authenticate_prometheus=False + command: bash -c './jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' working-dir: /opt/conda/bin/ platforms: amd64: diff --git a/jupyter-tensorflow-cuda-full/rockcraft.yaml b/jupyter-tensorflow-cuda-full/rockcraft.yaml index 1f4f31d..4f51d51 100644 --- a/jupyter-tensorflow-cuda-full/rockcraft.yaml +++ b/jupyter-tensorflow-cuda-full/rockcraft.yaml @@ -2,7 +2,7 @@ # https://github.com/kubeflow/kubeflow/blob/v1.7-branch/components/example-notebook-servers/base/Dockerfile # https://github.com/kubeflow/kubeflow/blob/v1.7-branch/components/example-notebook-servers/jupyter/Dockerfile # https://github.com/kubeflow/kubeflow/blob/v1.7-branch/components/example-notebook-servers/jupyter-tensorflow-full/cuda.Dockerfile -name: jupyter-tensorflow-cude-full +name: jupyter-tensorflow-cuda-full summary: An image for using Jupyter & Tensorflow on GPUs description: | This image is used as part of the Charmed Kubeflow product. It is deployed @@ -23,15 +23,16 @@ services: environment: NB_USER: jovyan NB_UID: 1001 - NB_PREFIX: / - HOME: /home/jovyan + # the following environment variables need to be present in the Pod environment + #HOME: "" + #NB_PREFIX: "" SHELL: /bin/bash LANG: en_US.UTF-8 LANGUAGE: en_US.UTF-8 LC_ALL: en_US.UTF-8 PATH: /opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin PYTHONPATH: /opt/conda/lib/python3.8/site-packages/ - command: ./jupyter lab --notebook-dir="/home/jovyan" --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url="/" --ServerApp.authenticate_prometheus=False + command: bash -c './jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' working-dir: /opt/conda/bin/ platforms: amd64: diff --git a/jupyter-tensorflow-full/rockcraft.yaml b/jupyter-tensorflow-full/rockcraft.yaml index 42441f6..21f5604 100644 --- a/jupyter-tensorflow-full/rockcraft.yaml +++ b/jupyter-tensorflow-full/rockcraft.yaml @@ -23,15 +23,16 @@ services: environment: NB_USER: jovyan NB_UID: 1001 - NB_PREFIX: / - HOME: /home/jovyan + # the following environment variables need to be present in the Pod environment + #HOME: "" + #NB_PREFIX: "" SHELL: /bin/bash LANG: en_US.UTF-8 LANGUAGE: en_US.UTF-8 LC_ALL: en_US.UTF-8 PATH: /opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin PYTHONPATH: /opt/conda/lib/python3.8/site-packages/ - command: ./jupyter lab --notebook-dir="/home/jovyan" --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url="/" --ServerApp.authenticate_prometheus=False + command: bash -c './jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' working-dir: /opt/conda/bin/ platforms: amd64: From 43d17c82725fb94bfd911af5d279691936397a8f Mon Sep 17 00:00:00 2001 From: Ivan Chvets Date: Thu, 5 Oct 2023 18:03:24 -0400 Subject: [PATCH 2/3] fix: added tests for env variables --- jupyter-pytorch-cuda-full/rockcraft.yaml | 2 +- jupyter-pytorch-cuda-full/tests/test_access.py | 13 +++++++++++-- jupyter-pytorch-full/rockcraft.yaml | 2 +- jupyter-pytorch-full/tests/test_access.py | 13 +++++++++++-- jupyter-scipy/rockcraft.yaml | 2 +- jupyter-scipy/tests/test_access.py | 13 +++++++++++-- jupyter-tensorflow-cuda-full/rockcraft.yaml | 2 +- jupyter-tensorflow-cuda-full/tests/test_access.py | 13 +++++++++++-- jupyter-tensorflow-full/rockcraft.yaml | 2 +- jupyter-tensorflow-full/tests/test_access.py | 13 +++++++++++-- 10 files changed, 60 insertions(+), 15 deletions(-) diff --git a/jupyter-pytorch-cuda-full/rockcraft.yaml b/jupyter-pytorch-cuda-full/rockcraft.yaml index 94b4cb2..905b599 100644 --- a/jupyter-pytorch-cuda-full/rockcraft.yaml +++ b/jupyter-pytorch-cuda-full/rockcraft.yaml @@ -19,7 +19,7 @@ services: environment: NB_USER: jovyan NB_UID: 1001 - # the following environment variables need to be present in the Pod environment + # The following environment variables need to be specified in the Pod's environment, and not hardcoded. #HOME: "" #NB_PREFIX: "" SHELL: /bin/bash diff --git a/jupyter-pytorch-cuda-full/tests/test_access.py b/jupyter-pytorch-cuda-full/tests/test_access.py index b7688bd..f6c9bf5 100644 --- a/jupyter-pytorch-cuda-full/tests/test_access.py +++ b/jupyter-pytorch-cuda-full/tests/test_access.py @@ -21,14 +21,19 @@ def main(): LOCAL_ROCK_IMAGE = f"{rock_image}:{rock_version}" print(f"Running {LOCAL_ROCK_IMAGE}") - container_id = subprocess.run(["docker", "run", "-d", "-p", "8888:8888", LOCAL_ROCK_IMAGE], stdout=subprocess.PIPE).stdout.decode('utf-8') + NB_PREFIX_DIR="test" + container_id = subprocess.run(["docker", "run", "-d", "-p", "8888:8888", "-e", f"NB_PREFIX={NB_PREFIX_DIR}", LOCAL_ROCK_IMAGE], stdout=subprocess.PIPE).stdout.decode('utf-8') container_id = container_id[0:12] # to ensure container is started time.sleep(5) # retrieve notebook server URL - output = subprocess.run(["curl", "http://127.0.0.1:8888/lab"], stdout=subprocess.PIPE).stdout.decode('utf-8') + output = subprocess.run(["curl", f"http://127.0.0.1:8888/{NB_PREFIX_DIR}/lab"], stdout=subprocess.PIPE).stdout.decode('utf-8') + + # retrieve logs + logs = subprocess.run(["docker", "logs", f"{container_id}"], stdout=subprocess.PIPE).stdout.decode('utf-8') + # cleanup subprocess.run(["docker", "stop", f"{container_id}"]) subprocess.run(["docker", "rm", f"{container_id}"]) @@ -36,6 +41,10 @@ def main(): # test output assert "JupyterLab" in output + # test logs + assert "Jupyter Server" in logs + assert f"http://127.0.0.1:8888/{NB_PREFIX_DIR}/lab" in logs + if __name__ == "__main__": main() diff --git a/jupyter-pytorch-full/rockcraft.yaml b/jupyter-pytorch-full/rockcraft.yaml index bf41594..7f8cfff 100644 --- a/jupyter-pytorch-full/rockcraft.yaml +++ b/jupyter-pytorch-full/rockcraft.yaml @@ -19,7 +19,7 @@ services: environment: NB_USER: jovyan NB_UID: 1001 - # the following environment variables need to be present in the Pod environment + # The following environment variables need to be specified in the Pod's environment, and not hardcoded. #HOME: "" #NB_PREFIX: "" SHELL: /bin/bash diff --git a/jupyter-pytorch-full/tests/test_access.py b/jupyter-pytorch-full/tests/test_access.py index b7688bd..f6c9bf5 100644 --- a/jupyter-pytorch-full/tests/test_access.py +++ b/jupyter-pytorch-full/tests/test_access.py @@ -21,14 +21,19 @@ def main(): LOCAL_ROCK_IMAGE = f"{rock_image}:{rock_version}" print(f"Running {LOCAL_ROCK_IMAGE}") - container_id = subprocess.run(["docker", "run", "-d", "-p", "8888:8888", LOCAL_ROCK_IMAGE], stdout=subprocess.PIPE).stdout.decode('utf-8') + NB_PREFIX_DIR="test" + container_id = subprocess.run(["docker", "run", "-d", "-p", "8888:8888", "-e", f"NB_PREFIX={NB_PREFIX_DIR}", LOCAL_ROCK_IMAGE], stdout=subprocess.PIPE).stdout.decode('utf-8') container_id = container_id[0:12] # to ensure container is started time.sleep(5) # retrieve notebook server URL - output = subprocess.run(["curl", "http://127.0.0.1:8888/lab"], stdout=subprocess.PIPE).stdout.decode('utf-8') + output = subprocess.run(["curl", f"http://127.0.0.1:8888/{NB_PREFIX_DIR}/lab"], stdout=subprocess.PIPE).stdout.decode('utf-8') + + # retrieve logs + logs = subprocess.run(["docker", "logs", f"{container_id}"], stdout=subprocess.PIPE).stdout.decode('utf-8') + # cleanup subprocess.run(["docker", "stop", f"{container_id}"]) subprocess.run(["docker", "rm", f"{container_id}"]) @@ -36,6 +41,10 @@ def main(): # test output assert "JupyterLab" in output + # test logs + assert "Jupyter Server" in logs + assert f"http://127.0.0.1:8888/{NB_PREFIX_DIR}/lab" in logs + if __name__ == "__main__": main() diff --git a/jupyter-scipy/rockcraft.yaml b/jupyter-scipy/rockcraft.yaml index ba9dc3c..b8af710 100644 --- a/jupyter-scipy/rockcraft.yaml +++ b/jupyter-scipy/rockcraft.yaml @@ -19,7 +19,7 @@ services: environment: NB_USER: jovyan NB_UID: 1001 - # the following environment variables need to be present in the Pod environment + # The following environment variables need to be specified in the Pod's environment, and not hardcoded. #HOME: "" #NB_PREFIX: "" SHELL: /bin/bash diff --git a/jupyter-scipy/tests/test_access.py b/jupyter-scipy/tests/test_access.py index b7688bd..f6c9bf5 100644 --- a/jupyter-scipy/tests/test_access.py +++ b/jupyter-scipy/tests/test_access.py @@ -21,14 +21,19 @@ def main(): LOCAL_ROCK_IMAGE = f"{rock_image}:{rock_version}" print(f"Running {LOCAL_ROCK_IMAGE}") - container_id = subprocess.run(["docker", "run", "-d", "-p", "8888:8888", LOCAL_ROCK_IMAGE], stdout=subprocess.PIPE).stdout.decode('utf-8') + NB_PREFIX_DIR="test" + container_id = subprocess.run(["docker", "run", "-d", "-p", "8888:8888", "-e", f"NB_PREFIX={NB_PREFIX_DIR}", LOCAL_ROCK_IMAGE], stdout=subprocess.PIPE).stdout.decode('utf-8') container_id = container_id[0:12] # to ensure container is started time.sleep(5) # retrieve notebook server URL - output = subprocess.run(["curl", "http://127.0.0.1:8888/lab"], stdout=subprocess.PIPE).stdout.decode('utf-8') + output = subprocess.run(["curl", f"http://127.0.0.1:8888/{NB_PREFIX_DIR}/lab"], stdout=subprocess.PIPE).stdout.decode('utf-8') + + # retrieve logs + logs = subprocess.run(["docker", "logs", f"{container_id}"], stdout=subprocess.PIPE).stdout.decode('utf-8') + # cleanup subprocess.run(["docker", "stop", f"{container_id}"]) subprocess.run(["docker", "rm", f"{container_id}"]) @@ -36,6 +41,10 @@ def main(): # test output assert "JupyterLab" in output + # test logs + assert "Jupyter Server" in logs + assert f"http://127.0.0.1:8888/{NB_PREFIX_DIR}/lab" in logs + if __name__ == "__main__": main() diff --git a/jupyter-tensorflow-cuda-full/rockcraft.yaml b/jupyter-tensorflow-cuda-full/rockcraft.yaml index 4f51d51..7a5b68c 100644 --- a/jupyter-tensorflow-cuda-full/rockcraft.yaml +++ b/jupyter-tensorflow-cuda-full/rockcraft.yaml @@ -23,7 +23,7 @@ services: environment: NB_USER: jovyan NB_UID: 1001 - # the following environment variables need to be present in the Pod environment + # The following environment variables need to be specified in the Pod's environment, and not hardcoded. #HOME: "" #NB_PREFIX: "" SHELL: /bin/bash diff --git a/jupyter-tensorflow-cuda-full/tests/test_access.py b/jupyter-tensorflow-cuda-full/tests/test_access.py index b7688bd..f6c9bf5 100644 --- a/jupyter-tensorflow-cuda-full/tests/test_access.py +++ b/jupyter-tensorflow-cuda-full/tests/test_access.py @@ -21,14 +21,19 @@ def main(): LOCAL_ROCK_IMAGE = f"{rock_image}:{rock_version}" print(f"Running {LOCAL_ROCK_IMAGE}") - container_id = subprocess.run(["docker", "run", "-d", "-p", "8888:8888", LOCAL_ROCK_IMAGE], stdout=subprocess.PIPE).stdout.decode('utf-8') + NB_PREFIX_DIR="test" + container_id = subprocess.run(["docker", "run", "-d", "-p", "8888:8888", "-e", f"NB_PREFIX={NB_PREFIX_DIR}", LOCAL_ROCK_IMAGE], stdout=subprocess.PIPE).stdout.decode('utf-8') container_id = container_id[0:12] # to ensure container is started time.sleep(5) # retrieve notebook server URL - output = subprocess.run(["curl", "http://127.0.0.1:8888/lab"], stdout=subprocess.PIPE).stdout.decode('utf-8') + output = subprocess.run(["curl", f"http://127.0.0.1:8888/{NB_PREFIX_DIR}/lab"], stdout=subprocess.PIPE).stdout.decode('utf-8') + + # retrieve logs + logs = subprocess.run(["docker", "logs", f"{container_id}"], stdout=subprocess.PIPE).stdout.decode('utf-8') + # cleanup subprocess.run(["docker", "stop", f"{container_id}"]) subprocess.run(["docker", "rm", f"{container_id}"]) @@ -36,6 +41,10 @@ def main(): # test output assert "JupyterLab" in output + # test logs + assert "Jupyter Server" in logs + assert f"http://127.0.0.1:8888/{NB_PREFIX_DIR}/lab" in logs + if __name__ == "__main__": main() diff --git a/jupyter-tensorflow-full/rockcraft.yaml b/jupyter-tensorflow-full/rockcraft.yaml index 21f5604..71d3566 100644 --- a/jupyter-tensorflow-full/rockcraft.yaml +++ b/jupyter-tensorflow-full/rockcraft.yaml @@ -23,7 +23,7 @@ services: environment: NB_USER: jovyan NB_UID: 1001 - # the following environment variables need to be present in the Pod environment + # The following environment variables need to be specified in the Pod's environment, and not hardcoded. #HOME: "" #NB_PREFIX: "" SHELL: /bin/bash diff --git a/jupyter-tensorflow-full/tests/test_access.py b/jupyter-tensorflow-full/tests/test_access.py index b7688bd..f6c9bf5 100644 --- a/jupyter-tensorflow-full/tests/test_access.py +++ b/jupyter-tensorflow-full/tests/test_access.py @@ -21,14 +21,19 @@ def main(): LOCAL_ROCK_IMAGE = f"{rock_image}:{rock_version}" print(f"Running {LOCAL_ROCK_IMAGE}") - container_id = subprocess.run(["docker", "run", "-d", "-p", "8888:8888", LOCAL_ROCK_IMAGE], stdout=subprocess.PIPE).stdout.decode('utf-8') + NB_PREFIX_DIR="test" + container_id = subprocess.run(["docker", "run", "-d", "-p", "8888:8888", "-e", f"NB_PREFIX={NB_PREFIX_DIR}", LOCAL_ROCK_IMAGE], stdout=subprocess.PIPE).stdout.decode('utf-8') container_id = container_id[0:12] # to ensure container is started time.sleep(5) # retrieve notebook server URL - output = subprocess.run(["curl", "http://127.0.0.1:8888/lab"], stdout=subprocess.PIPE).stdout.decode('utf-8') + output = subprocess.run(["curl", f"http://127.0.0.1:8888/{NB_PREFIX_DIR}/lab"], stdout=subprocess.PIPE).stdout.decode('utf-8') + + # retrieve logs + logs = subprocess.run(["docker", "logs", f"{container_id}"], stdout=subprocess.PIPE).stdout.decode('utf-8') + # cleanup subprocess.run(["docker", "stop", f"{container_id}"]) subprocess.run(["docker", "rm", f"{container_id}"]) @@ -36,6 +41,10 @@ def main(): # test output assert "JupyterLab" in output + # test logs + assert "Jupyter Server" in logs + assert f"http://127.0.0.1:8888/{NB_PREFIX_DIR}/lab" in logs + if __name__ == "__main__": main() From 8916c74bc5ddda06e791d51622c0fad56c36a5df Mon Sep 17 00:00:00 2001 From: Ivan Chvets Date: Mon, 30 Oct 2023 11:39:20 -0400 Subject: [PATCH 3/3] fix: home env variable setting Summary of changes: - Set HOME environment variable and sync it with working-dir - Updated version field to include dashes. --- jupyter-pytorch-cuda-full/rockcraft.yaml | 8 ++++---- jupyter-pytorch-full/rockcraft.yaml | 8 ++++---- jupyter-scipy/rockcraft.yaml | 8 ++++---- jupyter-tensorflow-cuda-full/rockcraft.yaml | 8 ++++---- jupyter-tensorflow-full/rockcraft.yaml | 8 ++++---- 5 files changed, 20 insertions(+), 20 deletions(-) diff --git a/jupyter-pytorch-cuda-full/rockcraft.yaml b/jupyter-pytorch-cuda-full/rockcraft.yaml index 905b599..f1f93e1 100644 --- a/jupyter-pytorch-cuda-full/rockcraft.yaml +++ b/jupyter-pytorch-cuda-full/rockcraft.yaml @@ -7,7 +7,7 @@ description: | Both PyTorch and Jupyter are installed in Conda environment, which is automatically activated. -version: v1.7.0_20.04_1 # version format: __ +version: v1.7.0-20.04-1 # version format: __ license: Apache-2.0 base: ubuntu:20.04 run-user: _daemon_ @@ -19,8 +19,8 @@ services: environment: NB_USER: jovyan NB_UID: 1001 + HOME: "/home/jovyan" # ensure that `working-dir` points to this directory # The following environment variables need to be specified in the Pod's environment, and not hardcoded. - #HOME: "" #NB_PREFIX: "" SHELL: /bin/bash LANG: en_US.UTF-8 @@ -31,8 +31,8 @@ services: NVIDIA_DRIVER_CAPABILITIES: compute,utility LD_LIBRARY_PATH: /usr/local/nvidia/lib:/usr/local/nvidia/lib64 PYTHONPATH: /opt/conda/lib/python3.8/site-packages/ - command: bash -c './jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' - working-dir: /opt/conda/bin/ + command: bash -c '/opt/conda/bin/jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' + working-dir: /home/jovyan platforms: amd64: diff --git a/jupyter-pytorch-full/rockcraft.yaml b/jupyter-pytorch-full/rockcraft.yaml index 7f8cfff..206e3bd 100644 --- a/jupyter-pytorch-full/rockcraft.yaml +++ b/jupyter-pytorch-full/rockcraft.yaml @@ -7,7 +7,7 @@ description: | Both PyTorch and Jupyter are installed in Conda environment, which is automatically activated. -version: v1.7.0_20.04_1 # version format: __ +version: v1.7.0-20.04-1 # version format: __ license: Apache-2.0 base: ubuntu:20.04 run-user: _daemon_ @@ -19,8 +19,8 @@ services: environment: NB_USER: jovyan NB_UID: 1001 + HOME: "/home/jovyan" # ensure that `working-dir` points to this directory # The following environment variables need to be specified in the Pod's environment, and not hardcoded. - #HOME: "" #NB_PREFIX: "" SHELL: /bin/bash LANG: en_US.UTF-8 @@ -28,8 +28,8 @@ services: LC_ALL: en_US.UTF-8 PATH: /opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin PYTHONPATH: /opt/conda/lib/python3.8/site-packages/ - command: bash -c './jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' - working-dir: /opt/conda/bin/ + command: bash -c '/opt/conda/bin/jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' + working-dir: /home/jovyan platforms: amd64: diff --git a/jupyter-scipy/rockcraft.yaml b/jupyter-scipy/rockcraft.yaml index b8af710..8d63400 100644 --- a/jupyter-scipy/rockcraft.yaml +++ b/jupyter-scipy/rockcraft.yaml @@ -7,7 +7,7 @@ description: | Both SciPy and Jupyter are installed in Conda environment, which is automatically activated. -version: v1.7.0_20.04_1 # version format: __ +version: v1.7.0-20.04-1 # version format: __ license: Apache-2.0 base: ubuntu:20.04 run-user: _daemon_ @@ -19,8 +19,8 @@ services: environment: NB_USER: jovyan NB_UID: 1001 + HOME: "/home/jovyan" # ensure that `working-dir` points to this directory # The following environment variables need to be specified in the Pod's environment, and not hardcoded. - #HOME: "" #NB_PREFIX: "" SHELL: /bin/bash LANG: en_US.UTF-8 @@ -28,8 +28,8 @@ services: LC_ALL: en_US.UTF-8 PATH: /opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin PYTHONPATH: /opt/conda/lib/python3.8/site-packages/ - command: bash -c './jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' - working-dir: /opt/conda/bin/ + command: bash -c '/opt/conda/bin/jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' + working-dir: /home/jovyan platforms: amd64: diff --git a/jupyter-tensorflow-cuda-full/rockcraft.yaml b/jupyter-tensorflow-cuda-full/rockcraft.yaml index 7a5b68c..ea95c54 100644 --- a/jupyter-tensorflow-cuda-full/rockcraft.yaml +++ b/jupyter-tensorflow-cuda-full/rockcraft.yaml @@ -11,7 +11,7 @@ description: | Both Tensorflow and Jupyter are installed in Conda environment, which is automatically activated. -version: v1.7.0_20.04_1 +version: v1.7.0-20.04-1 license: Apache-2.0 base: ubuntu:20.04 run-user: _daemon_ @@ -23,8 +23,8 @@ services: environment: NB_USER: jovyan NB_UID: 1001 + HOME: "/home/jovyan" # ensure that `working-dir` points to this directory # The following environment variables need to be specified in the Pod's environment, and not hardcoded. - #HOME: "" #NB_PREFIX: "" SHELL: /bin/bash LANG: en_US.UTF-8 @@ -32,8 +32,8 @@ services: LC_ALL: en_US.UTF-8 PATH: /opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin PYTHONPATH: /opt/conda/lib/python3.8/site-packages/ - command: bash -c './jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' - working-dir: /opt/conda/bin/ + command: bash -c '/opt/conda/bin/jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' + working-dir: /home/jovyan platforms: amd64: diff --git a/jupyter-tensorflow-full/rockcraft.yaml b/jupyter-tensorflow-full/rockcraft.yaml index 71d3566..72c5b3c 100644 --- a/jupyter-tensorflow-full/rockcraft.yaml +++ b/jupyter-tensorflow-full/rockcraft.yaml @@ -11,7 +11,7 @@ description: | Both Tensorflow and Jupyter are installed in Conda environment, which is automatically activated. -version: v1.7.0_20.04_1 +version: v1.7.0-20.04-1 license: Apache-2.0 base: ubuntu:20.04 run-user: _daemon_ @@ -23,8 +23,8 @@ services: environment: NB_USER: jovyan NB_UID: 1001 + HOME: "/home/jovyan" # ensure that `working-dir` points to this directory # The following environment variables need to be specified in the Pod's environment, and not hardcoded. - #HOME: "" #NB_PREFIX: "" SHELL: /bin/bash LANG: en_US.UTF-8 @@ -32,8 +32,8 @@ services: LC_ALL: en_US.UTF-8 PATH: /opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin PYTHONPATH: /opt/conda/lib/python3.8/site-packages/ - command: bash -c './jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' - working-dir: /opt/conda/bin/ + command: bash -c '/opt/conda/bin/jupyter lab --notebook-dir=${HOME} --ip=0.0.0.0 --no-browser --port=8888 --ServerApp.token="" --ServerApp.password="" --ServerApp.allow_origin="*" --ServerApp.base_url=${NB_PREFIX} --ServerApp.authenticate_prometheus=False' + working-dir: /home/jovyan platforms: amd64: