-
Notifications
You must be signed in to change notification settings - Fork 362
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to build locally. The command '/bin/sh -c TIMEFORMAT='time: %3R' bash -c 'time /tmp/install-base-env.bash' && rm -rf /tmp/install-base-env.bash /tmp/env' returned a non-zero code: 255% #1174
Comments
Thank you for opening your first issue in this project! Engagement like this is essential for open source projects! 🤗 |
I'm in a similar situation to @hkbertoson. I also tried to follow I though it might be because repo2docker only recently got the config option, as suggested in #1112, so I updated repo2docker from github. I'm still getting errors like "The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested" Hmmm, perhaps #1120 is where this discussion should go. Seems like @mattwigway did get it to work. I wonder if it was via the config.json file or the commandline option. I've tried pruning the Docker cache, but it seems like the argument isn't getting through to docker build? |
Hmmm, some progress. Reading
That's a bit weird as #1112 definitely says kwargs ... Changing from kwargs to args, pruning Docker, and re-running with:
made the However I did still run into the
error that @hkbertoson reports above. |
Trying to solve this issue: Also I tried to use repo2docker locally but had this issue: jupyterhub/repo2docker#1174
What version of repo2docker are you using ( |
Here's the output from my terminal session (on an M1 Pro Macbook). I'm trying to build from a repo on github. jlh5498@INFO-A64206 ~ % cd Documents/UTexas/images
jlh5498@INFO-A64206 images % mkdir repo2docker-issue
jlh5498@INFO-A64206 images % cd repo2docker-issue
jlh5498@INFO-A64206 repo2docker-issue % python3 -m pip install https://github.com/jupyterhub/repo2docker/archive/main.zip
DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621
Collecting https://github.com/jupyterhub/repo2docker/archive/main.zip
Using cached https://github.com/jupyterhub/repo2docker/archive/main.zip
Preparing metadata (setup.py) ... done
Requirement already satisfied: chardet in /opt/homebrew/lib/python3.9/site-packages (from jupyter-repo2docker==0+unknown) (4.0.0)
Requirement already satisfied: docker!=5.0.0 in /opt/homebrew/lib/python3.9/site-packages (from jupyter-repo2docker==0+unknown) (5.0.3)
Requirement already satisfied: entrypoints in /opt/homebrew/lib/python3.9/site-packages (from jupyter-repo2docker==0+unknown) (0.4)
Requirement already satisfied: escapism in /opt/homebrew/lib/python3.9/site-packages (from jupyter-repo2docker==0+unknown) (1.0.1)
Requirement already satisfied: iso8601 in /opt/homebrew/lib/python3.9/site-packages (from jupyter-repo2docker==0+unknown) (1.0.2)
Requirement already satisfied: jinja2 in /opt/homebrew/lib/python3.9/site-packages (from jupyter-repo2docker==0+unknown) (3.1.1)
Requirement already satisfied: python-json-logger in /opt/homebrew/lib/python3.9/site-packages (from jupyter-repo2docker==0+unknown) (2.0.2)
Requirement already satisfied: requests in /opt/homebrew/lib/python3.9/site-packages (from jupyter-repo2docker==0+unknown) (2.27.1)
Requirement already satisfied: ruamel.yaml>=0.15 in /opt/homebrew/lib/python3.9/site-packages (from jupyter-repo2docker==0+unknown) (0.17.21)
Requirement already satisfied: semver in /opt/homebrew/lib/python3.9/site-packages (from jupyter-repo2docker==0+unknown) (2.13.0)
Requirement already satisfied: toml in /opt/homebrew/lib/python3.9/site-packages (from jupyter-repo2docker==0+unknown) (0.10.2)
Requirement already satisfied: traitlets in /opt/homebrew/lib/python3.9/site-packages (from jupyter-repo2docker==0+unknown) (5.1.1)
Requirement already satisfied: websocket-client>=0.32.0 in /opt/homebrew/lib/python3.9/site-packages (from docker!=5.0.0->jupyter-repo2docker==0+unknown) (1.3.2)
Requirement already satisfied: urllib3<1.27,>=1.21.1 in /opt/homebrew/lib/python3.9/site-packages (from requests->jupyter-repo2docker==0+unknown) (1.26.9)
Requirement already satisfied: charset-normalizer~=2.0.0 in /opt/homebrew/lib/python3.9/site-packages (from requests->jupyter-repo2docker==0+unknown) (2.0.12)
Requirement already satisfied: certifi>=2017.4.17 in /opt/homebrew/lib/python3.9/site-packages (from requests->jupyter-repo2docker==0+unknown) (2021.10.8)
Requirement already satisfied: idna<4,>=2.5 in /opt/homebrew/lib/python3.9/site-packages (from requests->jupyter-repo2docker==0+unknown) (3.3)
Requirement already satisfied: ruamel.yaml.clib>=0.2.6 in /opt/homebrew/lib/python3.9/site-packages (from ruamel.yaml>=0.15->jupyter-repo2docker==0+unknown) (0.2.6)
Requirement already satisfied: MarkupSafe>=2.0 in /opt/homebrew/lib/python3.9/site-packages (from jinja2->jupyter-repo2docker==0+unknown) (2.1.1)
DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621
jlh5498@INFO-A64206 repo2docker-issue % which jupyter-repo2docker
/opt/homebrew/bin/jupyter-repo2docker
jlh5498@INFO-A64206 repo2docker-issue % jupyter-repo2docker --Repo2Docker.extra_build_args=platform=linux/amd64 https://github.com/2i2c-org/utexas-image.git
jlh5498@INFO-A64206 repo2docker-issue % uname -a
Darwin INFO-A64206 21.6.0 Darwin Kernel Version 21.6.0: Sat Jun 18 17:07:22 PDT 2022; root:xnu-8020.140.41~1/RELEASE_ARM64_T6000 arm64
jlh5498@INFO-A64206 repo2docker-issue % jupyter-repo2docker --Repo2Docker.extra_build_args=platform=linux/amd64 https://github.com/2i2c-org/utexas-image.git
Picked Git content provider.
Cloning into '/var/folders/61/pw3lcd0j7kx0mqzchqx2610w0000gq/T/repo2dockerdh_ci2dd'...
remote: Enumerating objects: 15, done.
remote: Counting objects: 100% (15/15), done.
remote: Compressing objects: 100% (11/11), done.
remote: Total 15 (delta 1), reused 8 (delta 0), pack-reused 0
Receiving objects: 100% (15/15), 4.89 KiB | 4.89 MiB/s, done.
Resolving deltas: 100% (1/1), done.
Using RBuildPack builder
Step 1/74 : FROM buildpack-deps:bionic
---> 284100b23017
Step 2/74 : ENV DEBIAN_FRONTEND=noninteractive
---> Using cache
---> 40e732cc5bac
Step 3/74 : RUN apt-get -qq update && apt-get -qq install --yes --no-install-recommends locales > /dev/null && apt-get -qq purge && apt-get -qq clean && rm -rf /var/lib/apt/lists/*
---> Using cache
---> de179bee0f49
Step 4/74 : RUN echo "en_US.UTF-8 UTF-8" > /etc/locale.gen && locale-gen
---> Using cache
---> f17224fbcec2
Step 5/74 : ENV LC_ALL en_US.UTF-8
---> Using cache
---> f045b0b0f4d5
Step 6/74 : ENV LANG en_US.UTF-8
---> Using cache
---> 3332a9351c34
Step 7/74 : ENV LANGUAGE en_US.UTF-8
---> Using cache
---> 8e8662232fae
Step 8/74 : ENV SHELL /bin/bash
---> Using cache
---> e945be631c12
Step 9/74 : ARG NB_USER
---> Using cache
---> f4c877336484
Step 10/74 : ARG NB_UID
---> Using cache
---> c83b7bf3ec0f
Step 11/74 : ENV USER ${NB_USER}
---> Using cache
---> 315f633499d5
Step 12/74 : ENV HOME /home/${NB_USER}
---> Using cache
---> b64cf4d5d1e6
Step 13/74 : RUN groupadd --gid ${NB_UID} ${NB_USER} && useradd --comment "Default user" --create-home --gid ${NB_UID} --no-log-init --shell /bin/bash --uid ${NB_UID} ${NB_USER}
---> Using cache
---> d376d9059bc2
Step 14/74 : RUN apt-get -qq update && apt-get -qq install --yes --no-install-recommends less unzip > /dev/null && apt-get -qq purge && apt-get -qq clean && rm -rf /var/lib/apt/lists/*
---> Using cache
---> 0dc6e8420457
Step 15/74 : RUN apt-get -qq update && apt-get -qq install --yes libapparmor1 lsb-release psmisc sudo > /dev/null && apt-get -qq purge && apt-get -qq clean && rm -rf /var/lib/apt/lists/*
---> Using cache
---> 8dfa1a75eb63
Step 16/74 : EXPOSE 8888
---> Using cache
---> 8ca40c5c8d6b
Step 17/74 : ENV APP_BASE /srv
---> Using cache
---> 7721c6fbced1
Step 18/74 : ENV CONDA_DIR ${APP_BASE}/conda
---> Using cache
---> 26517c424ba7
Step 19/74 : ENV NB_PYTHON_PREFIX ${CONDA_DIR}/envs/notebook
---> Using cache
---> 6e4b3a3b9a30
Step 20/74 : ENV NPM_DIR ${APP_BASE}/npm
---> Using cache
---> 20248b99ea9c
Step 21/74 : ENV NPM_CONFIG_GLOBALCONFIG ${NPM_DIR}/npmrc
---> Using cache
---> 75323fcb5b2b
Step 22/74 : ENV NB_ENVIRONMENT_FILE /tmp/env/environment.lock
---> Using cache
---> 6dba1b016dab
Step 23/74 : ENV MAMBA_ROOT_PREFIX ${CONDA_DIR}
---> Using cache
---> ddd0f6789606
Step 24/74 : ENV MAMBA_EXE ${CONDA_DIR}/bin/mamba
---> Using cache
---> 9ffb7cb9f0bd
Step 25/74 : ENV KERNEL_PYTHON_PREFIX ${NB_PYTHON_PREFIX}
---> Using cache
---> 983ec0fec877
Step 26/74 : ENV R_LIBS_USER ${APP_BASE}/rlibs
---> Using cache
---> ed34cee0f4d4
Step 27/74 : ENV PATH ${NB_PYTHON_PREFIX}/bin:${CONDA_DIR}/bin:${NPM_DIR}/bin:/usr/lib/rstudio-server/bin/:${PATH}
---> Using cache
---> 03b190ae487c
Step 28/74 : COPY --chown=503:503 build_script_files/-2fopt-2fhomebrew-2flib-2fpython3-2e9-2fsite-2dpackages-2frepo2docker-2fbuildpacks-2fconda-2factivate-2dconda-2esh-a87dba /etc/profile.d/activate-conda.sh
---> Using cache
---> 9d3380ce1cc6
Step 29/74 : COPY --chown=503:503 build_script_files/-2fopt-2fhomebrew-2flib-2fpython3-2e9-2fsite-2dpackages-2frepo2docker-2fbuildpacks-2fconda-2fenvironment-2epy-2d3-2e7-2elock-a461dc /tmp/env/environment.lock
---> Using cache
---> 76e099d83276
Step 30/74 : COPY --chown=503:503 build_script_files/-2fopt-2fhomebrew-2flib-2fpython3-2e9-2fsite-2dpackages-2frepo2docker-2fbuildpacks-2fconda-2finstall-2dbase-2denv-2ebash-1ca25f /tmp/install-base-env.bash
---> Using cache
---> 217f5f8d8b00
Step 31/74 : RUN TIMEFORMAT='time: %3R' bash -c 'time /tmp/install-base-env.bash' && rm -rf /tmp/install-base-env.bash /tmp/env
---> Running in ed81165b88c8
++ dirname /tmp/install-base-env.bash
+ cd /tmp
+ export MAMBA_VERSION=0.25.0
+ MAMBA_VERSION=0.25.0
+ export CONDA_VERSION=4.13.0
+ CONDA_VERSION=4.13.0
+ URL=https://anaconda.org/conda-forge/micromamba/0.25.0/download/linux-64/micromamba-0.25.0-0.tar.bz2
+ unset HOME
+ mkdir -p /srv/conda
+ export MICROMAMBA_EXE=/usr/local/bin/micromamba
+ MICROMAMBA_EXE=/usr/local/bin/micromamba
+ wget -qO- https://anaconda.org/conda-forge/micromamba/0.25.0/download/linux-64/micromamba-0.25.0-0.tar.bz2
+ tar -xvj bin/micromamba
bin/micromamba
time: 1.789
+ mv bin/micromamba /usr/local/bin/micromamba
+ chmod 0755 /usr/local/bin/micromamba
++ /usr/local/bin/micromamba shell hook -p /srv/conda -s posix
qemu-x86_64: Could not open '/lib64/ld-linux-x86-64.so.2': No such file or directory
+ eval ''
+ micromamba activate
qemu-x86_64: Could not open '/lib64/ld-linux-x86-64.so.2': No such file or directory
time: 1.809
Removing intermediate container ed81165b88c8
The command '/bin/sh -c TIMEFORMAT='time: %3R' bash -c 'time /tmp/install-base-env.bash' && rm -rf /tmp/install-base-env.bash /tmp/env' returned a non-zero code: 255% jlh5498@INFO-A64206 repo2docker-issue % |
Does the error go away if you clear your image caches? I ran into this, and setting platform=linux/amd64 worked (as is done in your extra_build_args), but only after removing the build cache (I did |
I was able to get this to build by:
Thanks for the help. I still don't understand why it is |
Bug description
I am unable to use
repo2docker
to build a local directory.Expected behaviour
repo2docker
to build locallyActual behaviour
It fails
How to reproduce
Create new directory and run
repo2docker
Your personal set up
docker version
20.10.17repo2docker --version
2022.02.0I did see #1112 (comment) as a workaround. But I could not get this working either.
The text was updated successfully, but these errors were encountered: