Error when building a new image from jupyterhub/singleuser:3.0.0

Hi, I’m trying to build a new docker image using jupyterhub/singleuser:3.0.0 as base image. This is the Dockerfile:

FROM jupyterhub/singleuser:3.0.0
RUN mamba install --quiet --yes \
    'tensorflow' && \
    mamba clean --all -f -y && \
    fix-permissions "${CONDA_DIR}" && \
    fix-permissions "/home/${NB_USER}"

However I’m facing the following errors:

Step 2/12 : RUN mamba install --quiet --yes     'tensorflow' &&     mamba clean --all -f -y &&     fix-permissions "${CONDA_DIR}" &&     fix-permissions "/home/${NB_USER}"
 ---> Running in a3bc1398de47
Operation not permitted

# >>>>>>>>>>>>>>>>>>>>>> ERROR REPORT <<<<<<<<<<<<<<<<<<<<<<

    Traceback (most recent call last):
      File "/opt/conda/lib/python3.10/site-packages/conda/exceptions.py", line 1125, in __call__
        return func(*args, **kwargs)
      File "/opt/conda/lib/python3.10/site-packages/mamba/mamba.py", line 935, in exception_converter
        raise e
      File "/opt/conda/lib/python3.10/site-packages/mamba/mamba.py", line 928, in exception_converter
        exit_code = _wrapped_main(*args, **kwargs)
      File "/opt/conda/lib/python3.10/site-packages/mamba/mamba.py", line 886, in _wrapped_main
        result = do_call(args, p)
      File "/opt/conda/lib/python3.10/site-packages/mamba/mamba.py", line 750, in do_call
        exit_code = install(args, parser, "install")
      File "/opt/conda/lib/python3.10/site-packages/mamba/mamba.py", line 258, in install
        init_api_context(use_mamba_experimental)
      File "/opt/conda/lib/python3.10/site-packages/mamba/utils.py", line 197, in init_api_context
        api_ctx = api.Context()
    RuntimeError: Operation not permitted

Any idea on how to fix this?

Thanks!

Your example Dockerfile built successfully for me. Are you running into an operating system error?

I tried on two different systems: in both cases it works with singleuser v2.3.0, but not with 3.0.0

Which docker version are you using?

Issue fixed by upgrading Docker to the latest version.