b-data / jupyterlab-mojo-docker-stack

Multi-arch (linux/amd64, linux/arm64/v8) JupyterLab Mojo docker images. Please submit Pull Requests to the GitLab repository. Mirror of
https://gitlab.com/b-data/jupyterlab/mojo/docker-stack
Other
1 stars 0 forks source link

Failed to install on Linux #3

Open itsgifnotjiff opened 1 week ago

itsgifnotjiff commented 1 week ago

Tried to install it on

Linux NAME 5.15.0-50-generic #56-Ubuntu SMP Tue Sep 20 13:23:26 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

using Docker version 24.0.6, build ed223bc but I got to

Step 53/90 : ENV PARENT_IMAGE=${BUILD_ON_IMAGE}${PYTHON_VERSION:+:}${PYTHON_VERSION}${CUDA_IMAGE_FLAVOR:+-}${CUDA_IMAGE_FLAVOR}     MODULAR_HOME=/opt/modular     MOJO_VERSION=${MOJO_VERSION%%-*}     NB_USER=${NB_USER}     NB_UID=${NB_UID}     JUPYTERHUB_VERSION=${JUPYTERHUB_VERSION}     JUPYTERLAB_VERSION=${JUPYTERLAB_VERSION}     CODE_SERVER_VERSION=${CODE_SERVER_VERSION}     GIT_VERSION=${GIT_VERSION}     GIT_LFS_VERSION=${GIT_LFS_VERSION}     PANDOC_VERSION=${PANDOC_VERSION}
failed to process "${MOJO_VERSION%%-*}": missing ':' in substitution
benz0li commented 1 week ago

@itsgifnotjiff Why don't you use the pre-built images? I.e. glcr.b-data.ch/jupyterlab/mojo/base or glcr.b-data.ch/jupyterlab/mojo/scipy?

benz0li commented 1 week ago

@itsgifnotjiff Variable expansion is only supported for a limited set of Dockerfile instructions.

If you want to build the images with a Docker version < 26.0.0, you need to add # syntax=docker/dockerfile-upstream:master at the very top of the 24.3.0.Dockerfile or latest.Dockerfile.

itsgifnotjiff commented 1 week ago

@itsgifnotjiff Why don't you use the pre-built images? I.e. glcr.b-data.ch/jupyterlab/mojo/base or glcr.b-data.ch/jupyterlab/mojo/scipy?

Should I do that sir? I just found your repo and assumed it is the "right" way to do it. My goal is to experiment with MAX and Mojo on an HPC with GPU clusters for atmospheric ML models (Graphcast and such). Does that fit this repo default or should I change to something else?

Thank you so much for your wonderful work ☺️

itsgifnotjiff commented 1 week ago

@itsgifnotjiff Variable expansion is only supported for a limited set of Dockerfile instructions.

If you want to build the images with a Docker version < 26.0.0, you need to add # syntax=docker/dockerfile-upstream:master at the very top of the 24.3.0.Dockerfile or latest.Dockerfile.

This does not work sir. I get

DEPRECATED: The legacy builder is deprecated and will be removed in a future release.
            Install the buildx component to build images with BuildKit:
            https://docs.docker.com/go/buildx/

Does the command

cd base && docker build \
  --build-arg MODULAR_VERSION=0.8.0 \
  --build-arg MOJO_VERSION=24.4.0 \
  --build-arg PYTHON_VERSION=3.12.4 \
  -t jupyterlab/mojo/base \
  -f latest.Dockerfile .

work for you out of the gate? I don't want to waste your time but I appreciate your guidance :)

benz0li commented 1 week ago

@itsgifnotjiff Why don't you use the pre-built images? I.e. glcr.b-data.ch/jupyterlab/mojo/base or glcr.b-data.ch/jupyterlab/mojo/scipy?

Should I do that sir? I just found your repo and assumed it is the "right" way to do it.

Either way is fine.

My goal is to experiment with MAX and Mojo on an HPC with GPU clusters for atmospheric ML models (Graphcast and such). Does that fit this repo default or should I change to something else?

The current images provide just Mojo. 'MAX Engine'-based images will be published as soon as the MAX Engine supports Python 3.12.
ℹ️ Currently, only Python 3.8 - 3.11 is supported.

Cross references:

Furthermore, the MAX Engine does not support NVIDIA GPUs yet: https://docs.modular.com/engine/faq#what-hardware-is-currently-supported-by-max-engine

GPU accelerated 'MAX Engine'-based images will be published as soon as the MAX Engine supports Python 3.12 and NVIDIA GPUs.
ℹ️ Supposedly this summer: https://twitter.com/Modular/status/1785131461345157140

Cross reference:

Thank you so much for your wonderful work ☺️

You are welcome.

benz0li commented 1 week ago

@itsgifnotjiff Variable expansion is only supported for a limited set of Dockerfile instructions. If you want to build the images with a Docker version < 26.0.0, you need to add # syntax=docker/dockerfile-upstream:master at the very top of the 24.3.0.Dockerfile or latest.Dockerfile.

This does not work sir. I get

DEPRECATED: The legacy builder is deprecated and will be removed in a future release.
            Install the buildx component to build images with BuildKit:
            https://docs.docker.com/go/buildx/

Does the command

cd base && docker build \
  --build-arg MODULAR_VERSION=0.8.0 \
  --build-arg MOJO_VERSION=24.4.0 \
  --build-arg PYTHON_VERSION=3.12.4 \
  -t jupyterlab/mojo/base \
  -f latest.Dockerfile .

work for you out of the gate? I don't want to waste your time but I appreciate your guidance :)

Yes.

To build 'MAX Engine'-based images yourself:

cd base
docker build \
  --build-arg MODULAR_VERSION=0.8.0 \
  --build-arg MODULAR_AUTH_KEY=<your-modular-auth-key> \
  --build-arg MOJO_VERSION=24.4.0 \
  --build-arg INSTALL_MAX=1 \
  --build-arg PYTHON_VERSION=3.11.9 \
  -t jupyterlab/mojo-max/base \
  -f latest.Dockerfile .
benz0li commented 1 week ago

Building yourself will only work, if you install the latest Docker Engine from Docker's apt repository.

Please follow the instructions for your platform (Ubuntu):