vscode-dev-containers icon indicating copy to clipboard operation
vscode-dev-containers copied to clipboard

Azure Machine Learning Dockerfile fails to build

Open jamescrowley opened this issue 3 years ago • 2 comments

  • VSCode Version: 1.69.2
  • Local OS Version: macOS 12.5
  • Local chip architecture: Apple Silicon
  • Reproduces in: Remote - Containers
  • Name of Dev Container Definition with Issue: Azure Machine Learning

Steps to Reproduce:

Found this via dev containers, but the problem is directly with https://github.com/microsoft/vscode-dev-containers/blob/main/containers/azure-machine-learning-python-3/.devcontainer/Dockerfile - just try to docker build this. It fails (at least on my machine!) with the following:

[+] Building 0.0s (1/2)                                                                                           
 => [internal] load build definition from Dockerfile                                                         0.0s
 => => transferring dockerfile: 2B                                                                           0.0s
failed to solve with frontend dockerfile.v0: failed to read dockerfile: open /var/lib/docker/tmp/buildkit-mount558440908/Dockerfile: no such file or directory
(base) jcrowley@macbook-pro-14 .devcontainer2 % docker build .
[+] Building 12.1s (5/5) FINISHED                                                                                 
 => [internal] load build definition from Dockerfile                                                         0.0s
 => => transferring dockerfile: 3.67kB                                                                       0.0s
 => [internal] load .dockerignore                                                                            0.0s
 => => transferring context: 2B                                                                              0.0s
 => [internal] load metadata for mcr.microsoft.com/vscode/devcontainers/base:ubuntu-18.04                    0.7s
 => CACHED [1/2] FROM mcr.microsoft.com/vscode/devcontainers/base:ubuntu-18.04@sha256:4a97767a653276e0e4762  0.0s
 => ERROR [2/2] RUN apt-get update     && export DEBIAN_FRONTEND=noninteractive     && if [ "1000" != "100  11.3s
------                                                                                                            
 > [2/2] RUN apt-get update     && export DEBIAN_FRONTEND=noninteractive     && if [ "1000" != "1000" ] || [ "1000" != "1000" ]; then         groupmod --gid 1000 vscode         && usermod --uid 1000 --gid 1000 vscode         && chown -R 1000:1000 /home/vscode;     fi     && apt-get install -y gnupg-agent software-properties-common     && curl -fsSL https://download.docker.com/linux/$(lsb_release -is | tr '[:upper:]' '[:lower:]')/gpg | (OUT=$(apt-key add - 2>&1) || echo $OUT)     && add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/$(lsb_release -is | tr '[:upper:]' '[:lower:]') $(lsb_release -cs) stable"     && apt-get update     && apt-get install -y docker-ce-cli     && apt-get install -y bzip2 libglib2.0-0 libxext6 libsm6 libxrender1 gcc g++     && mkdir -p /opt/conda     && chown vscode:root /opt/conda     && echo "Downloading Anaconda..."     && su --login -c "wget -q https://repo.anaconda.com/archive/Anaconda3-2020.02-Linux-x86_64.sh -O /tmp/anaconda-install.sh         && /bin/bash /tmp/anaconda-install.sh -u -b -p /opt/conda" vscode 2>&1      && rm /tmp/anaconda-install.sh     && ln -s /opt/conda/etc/profile.d/conda.sh /etc/profile.d/conda.sh     && export SNIPPET="export PATH=$PATH:$HOME/.local/bin         && if [ "$(stat -c '%U' /opt/conda)" != "vscode" ]; then             sudo chown -R vscode:root /opt/conda;         fi         && . /opt/conda/etc/profile.d/conda.sh         && conda activate base"     && echo "$SNIPPET" | tee -a /root/.bashrc >> /home/vscode/.bashrc     && echo "$SNIPPET" | tee -a /root/.zshrc >> /home/vscode/.zshrc     && find /opt/conda/ -follow -type f -name '*.a' -delete     && find /opt/conda/ -follow -type f -name '*.js.map' -delete     && /opt/conda/bin/conda clean -afy     && su --login -c "/opt/conda/bin/pip install --no-cache-dir --upgrade azureml-sdk[notebooks,automl]" vscode 2>&1     && apt-get autoremove -y     && apt-get clean -y     && rm -rf /var/lib/apt/lists/*:
#5 0.324 Get:1 http://ports.ubuntu.com/ubuntu-ports bionic InRelease [242 kB]
#5 0.473 Get:2 http://ports.ubuntu.com/ubuntu-ports bionic-updates InRelease [88.7 kB]
#5 0.508 Get:3 http://ports.ubuntu.com/ubuntu-ports bionic-backports InRelease [74.6 kB]
#5 0.543 Get:4 http://ports.ubuntu.com/ubuntu-ports bionic-security InRelease [88.7 kB]
#5 0.588 Get:5 http://ports.ubuntu.com/ubuntu-ports bionic/main arm64 Packages [1285 kB]
#5 0.669 Get:6 http://ports.ubuntu.com/ubuntu-ports bionic/restricted arm64 Packages [572 B]
#5 0.669 Get:7 http://ports.ubuntu.com/ubuntu-ports bionic/universe arm64 Packages [11.0 MB]
#5 1.033 Get:8 http://ports.ubuntu.com/ubuntu-ports bionic/multiverse arm64 Packages [153 kB]
#5 1.036 Get:9 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 Packages [1997 kB]
#5 1.063 Get:10 http://ports.ubuntu.com/ubuntu-ports bionic-updates/restricted arm64 Packages [5476 B]
#5 1.063 Get:11 http://ports.ubuntu.com/ubuntu-ports bionic-updates/universe arm64 Packages [2059 kB]
#5 1.103 Get:12 http://ports.ubuntu.com/ubuntu-ports bionic-updates/multiverse arm64 Packages [5354 B]
#5 1.104 Get:13 http://ports.ubuntu.com/ubuntu-ports bionic-backports/main arm64 Packages [12.2 kB]
#5 1.104 Get:14 http://ports.ubuntu.com/ubuntu-ports bionic-backports/universe arm64 Packages [12.5 kB]
#5 1.105 Get:15 http://ports.ubuntu.com/ubuntu-ports bionic-security/main arm64 Packages [1617 kB]
#5 1.189 Get:16 http://ports.ubuntu.com/ubuntu-ports bionic-security/restricted arm64 Packages [4803 B]
#5 1.189 Get:17 http://ports.ubuntu.com/ubuntu-ports bionic-security/universe arm64 Packages [1362 kB]
#5 1.207 Get:18 http://ports.ubuntu.com/ubuntu-ports bionic-security/multiverse arm64 Packages [2755 B]
#5 2.217 Fetched 20.0 MB in 2s (10.5 MB/s)
#5 2.217 Reading package lists...
#5 2.960 Reading package lists...
#5 3.597 Building dependency tree...
#5 3.700 Reading state information...
#5 3.803 The following additional packages will be installed:
#5 3.803   dirmngr gnupg gnupg-l10n gnupg-utils gpg gpg-agent gpg-wks-client
#5 3.803   gpg-wks-server gpgconf gpgsm gpgv python3-software-properties
#5 3.803   unattended-upgrades
#5 3.803 Suggested packages:
#5 3.803   dbus-user-session pinentry-gnome3 tor parcimonie xloadimage scdaemon
#5 3.803   bsd-mailx default-mta | mail-transport-agent needrestart
#5 3.839 The following NEW packages will be installed:
#5 3.839   gnupg-agent python3-software-properties software-properties-common
#5 3.839   unattended-upgrades
#5 3.839 The following packages will be upgraded:
#5 3.839   dirmngr gnupg gnupg-l10n gnupg-utils gpg gpg-agent gpg-wks-client
#5 3.840   gpg-wks-server gpgconf gpgsm gpgv
#5 3.925 11 upgraded, 4 newly installed, 0 to remove and 12 not upgraded.
#5 3.925 Need to get 1957 kB of archives.
#5 3.925 After this operation, 797 kB of additional disk space will be used.
#5 3.925 Get:1 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 gpg-wks-client arm64 2.2.4-1ubuntu1.6 [76.6 kB]
#5 4.047 Get:2 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 dirmngr arm64 2.2.4-1ubuntu1.6 [276 kB]
#5 4.121 Get:3 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 gpg arm64 2.2.4-1ubuntu1.6 [401 kB]
#5 4.163 Get:4 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 gnupg-utils arm64 2.2.4-1ubuntu1.6 [108 kB]
#5 4.175 Get:5 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 gnupg-l10n all 2.2.4-1ubuntu1.6 [50.1 kB]
#5 4.177 Get:6 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 gpg-agent arm64 2.2.4-1ubuntu1.6 [189 kB]
#5 4.186 Get:7 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 gpgsm arm64 2.2.4-1ubuntu1.6 [181 kB]
#5 4.195 Get:8 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 gpgconf arm64 2.2.4-1ubuntu1.6 [107 kB]
#5 4.199 Get:9 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 gnupg arm64 2.2.4-1ubuntu1.6 [249 kB]
#5 4.208 Get:10 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 gpg-wks-server arm64 2.2.4-1ubuntu1.6 [71.6 kB]
#5 4.209 Get:11 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 gpgv arm64 2.2.4-1ubuntu1.6 [167 kB]
#5 4.214 Get:12 http://ports.ubuntu.com/ubuntu-ports bionic-updates/universe arm64 gnupg-agent all 2.2.4-1ubuntu1.6 [4868 B]
#5 4.214 Get:13 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 python3-software-properties all 0.96.24.32.18 [23.8 kB]
#5 4.215 Get:14 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 software-properties-common all 0.96.24.32.18 [10.1 kB]
#5 4.215 Get:15 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 unattended-upgrades all 1.1ubuntu1.18.04.14 [41.7 kB]
#5 5.053 Preconfiguring packages ...
#5 5.096 Fetched 1957 kB in 0s (5333 kB/s)
(Reading database ... 24074 files and directories currently installed.)
#5 5.132 Preparing to unpack .../00-gpg-wks-client_2.2.4-1ubuntu1.6_arm64.deb ...
#5 5.138 Unpacking gpg-wks-client (2.2.4-1ubuntu1.6) over (2.2.4-1ubuntu1.5) ...
#5 5.179 Preparing to unpack .../01-dirmngr_2.2.4-1ubuntu1.6_arm64.deb ...
#5 5.211 Unpacking dirmngr (2.2.4-1ubuntu1.6) over (2.2.4-1ubuntu1.5) ...
#5 5.284 Preparing to unpack .../02-gpg_2.2.4-1ubuntu1.6_arm64.deb ...
#5 5.292 Unpacking gpg (2.2.4-1ubuntu1.6) over (2.2.4-1ubuntu1.5) ...
#5 5.348 Preparing to unpack .../03-gnupg-utils_2.2.4-1ubuntu1.6_arm64.deb ...
#5 5.356 Unpacking gnupg-utils (2.2.4-1ubuntu1.6) over (2.2.4-1ubuntu1.5) ...
#5 5.413 Preparing to unpack .../04-gnupg-l10n_2.2.4-1ubuntu1.6_all.deb ...
#5 5.421 Unpacking gnupg-l10n (2.2.4-1ubuntu1.6) over (2.2.4-1ubuntu1.5) ...
#5 5.490 Preparing to unpack .../05-gpg-agent_2.2.4-1ubuntu1.6_arm64.deb ...
#5 5.497 Unpacking gpg-agent (2.2.4-1ubuntu1.6) over (2.2.4-1ubuntu1.5) ...
#5 5.561 Preparing to unpack .../06-gpgsm_2.2.4-1ubuntu1.6_arm64.deb ...
#5 5.568 Unpacking gpgsm (2.2.4-1ubuntu1.6) over (2.2.4-1ubuntu1.5) ...
#5 5.608 Preparing to unpack .../07-gpgconf_2.2.4-1ubuntu1.6_arm64.deb ...
#5 5.615 Unpacking gpgconf (2.2.4-1ubuntu1.6) over (2.2.4-1ubuntu1.5) ...
#5 5.659 Preparing to unpack .../08-gnupg_2.2.4-1ubuntu1.6_arm64.deb ...
#5 5.666 Unpacking gnupg (2.2.4-1ubuntu1.6) over (2.2.4-1ubuntu1.5) ...
#5 5.715 Preparing to unpack .../09-gpg-wks-server_2.2.4-1ubuntu1.6_arm64.deb ...
#5 5.722 Unpacking gpg-wks-server (2.2.4-1ubuntu1.6) over (2.2.4-1ubuntu1.5) ...
#5 5.757 Preparing to unpack .../10-gpgv_2.2.4-1ubuntu1.6_arm64.deb ...
#5 5.764 Unpacking gpgv (2.2.4-1ubuntu1.6) over (2.2.4-1ubuntu1.5) ...
#5 5.810 Setting up gpgv (2.2.4-1ubuntu1.6) ...
#5 5.836 Selecting previously unselected package gnupg-agent.
(Reading database ... 24074 files and directories currently installed.)
#5 5.845 Preparing to unpack .../gnupg-agent_2.2.4-1ubuntu1.6_all.deb ...
#5 5.848 Unpacking gnupg-agent (2.2.4-1ubuntu1.6) ...
#5 5.873 Selecting previously unselected package python3-software-properties.
#5 5.875 Preparing to unpack .../python3-software-properties_0.96.24.32.18_all.deb ...
#5 5.877 Unpacking python3-software-properties (0.96.24.32.18) ...
#5 5.906 Selecting previously unselected package software-properties-common.
#5 5.908 Preparing to unpack .../software-properties-common_0.96.24.32.18_all.deb ...
#5 5.911 Unpacking software-properties-common (0.96.24.32.18) ...
#5 5.946 Selecting previously unselected package unattended-upgrades.
#5 5.948 Preparing to unpack .../unattended-upgrades_1.1ubuntu1.18.04.14_all.deb ...
#5 5.950 Unpacking unattended-upgrades (1.1ubuntu1.18.04.14) ...
#5 5.985 Setting up gpgconf (2.2.4-1ubuntu1.6) ...
#5 5.993 Setting up gpg-agent (2.2.4-1ubuntu1.6) ...
#5 6.006 Setting up gnupg-l10n (2.2.4-1ubuntu1.6) ...
#5 6.013 Setting up gpgsm (2.2.4-1ubuntu1.6) ...
#5 6.020 Setting up gnupg-utils (2.2.4-1ubuntu1.6) ...
#5 6.026 Setting up unattended-upgrades (1.1ubuntu1.18.04.14) ...
#5 6.132 
#5 6.132 Creating config file /etc/apt/apt.conf.d/20auto-upgrades with new version
#5 6.206 
#5 6.206 Creating config file /etc/apt/apt.conf.d/50unattended-upgrades with new version
#5 6.381 Created symlink /etc/systemd/system/multi-user.target.wants/unattended-upgrades.service → /lib/systemd/system/unattended-upgrades.service.
#5 6.467 Setting up gnupg-agent (2.2.4-1ubuntu1.6) ...
#5 6.475 Setting up dirmngr (2.2.4-1ubuntu1.6) ...
#5 6.497 Setting up gpg (2.2.4-1ubuntu1.6) ...
#5 6.505 Setting up gpg-wks-server (2.2.4-1ubuntu1.6) ...
#5 6.512 Setting up gpg-wks-client (2.2.4-1ubuntu1.6) ...
#5 6.518 Setting up python3-software-properties (0.96.24.32.18) ...
#5 6.636 Setting up software-properties-common (0.96.24.32.18) ...
#5 6.746 Setting up gnupg (2.2.4-1ubuntu1.6) ...
#5 6.753 Processing triggers for man-db (2.8.3-2ubuntu0.1) ...
#5 6.985 Processing triggers for dbus (1.12.2-1ubuntu1.3) ...
#5 6.992 Processing triggers for ureadahead (0.100.0-21) ...
#5 7.004 Processing triggers for install-info (6.5.0.dfsg.1-2) ...
#5 7.063 Processing triggers for systemd (237-3ubuntu10.53) ...
#5 7.913 Hit:1 http://ports.ubuntu.com/ubuntu-ports bionic InRelease
#5 7.939 Hit:2 http://ports.ubuntu.com/ubuntu-ports bionic-updates InRelease
#5 7.968 Hit:3 http://ports.ubuntu.com/ubuntu-ports bionic-backports InRelease
#5 7.996 Hit:4 http://ports.ubuntu.com/ubuntu-ports bionic-security InRelease
#5 8.029 Get:5 https://download.docker.com/linux/ubuntu bionic InRelease [64.4 kB]
#5 8.296 Get:6 https://download.docker.com/linux/ubuntu bionic/stable amd64 Packages [30.5 kB]
#5 8.349 Fetched 94.9 kB in 0s (206 kB/s)
#5 8.349 Reading package lists...
#5 9.226 Hit:1 http://ports.ubuntu.com/ubuntu-ports bionic InRelease
#5 9.249 Hit:2 http://ports.ubuntu.com/ubuntu-ports bionic-updates InRelease
#5 9.250 Hit:3 https://download.docker.com/linux/ubuntu bionic InRelease
#5 9.276 Hit:4 http://ports.ubuntu.com/ubuntu-ports bionic-backports InRelease
#5 9.302 Hit:5 http://ports.ubuntu.com/ubuntu-ports bionic-security InRelease
#5 9.640 Reading package lists...
#5 10.38 Reading package lists...
#5 11.07 Building dependency tree...
#5 11.20 Reading state information...
#5 11.22 E: Unable to locate package docker-ce-cli
------
executor failed running [/bin/sh -c apt-get update     && export DEBIAN_FRONTEND=noninteractive     && if [ "$USER_GID" != "1000" ] || [ "$USER_UID" != "1000" ]; then         groupmod --gid $USER_GID $USERNAME         && usermod --uid $USER_UID --gid $USER_GID $USERNAME         && chown -R $USER_UID:$USER_GID /home/$USERNAME;     fi     && apt-get install -y gnupg-agent software-properties-common     && curl -fsSL https://download.docker.com/linux/$(lsb_release -is | tr '[:upper:]' '[:lower:]')/gpg | (OUT=$(apt-key add - 2>&1) || echo $OUT)     && add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/$(lsb_release -is | tr '[:upper:]' '[:lower:]') $(lsb_release -cs) stable"     && apt-get update     && apt-get install -y docker-ce-cli     && apt-get install -y bzip2 libglib2.0-0 libxext6 libsm6 libxrender1 gcc g++     && mkdir -p ${CONDA_INSTALL_PATH}     && chown ${USERNAME}:root /opt/conda     && echo "Downloading Anaconda..."     && su --login -c "wget -q https://repo.anaconda.com/archive/Anaconda3-${ANACONDA_VERSION}-Linux-x86_64.sh -O /tmp/anaconda-install.sh         && /bin/bash /tmp/anaconda-install.sh -u -b -p ${CONDA_INSTALL_PATH}" ${USERNAME} 2>&1      && rm /tmp/anaconda-install.sh     && ln -s ${CONDA_INSTALL_PATH}/etc/profile.d/conda.sh /etc/profile.d/conda.sh     && export SNIPPET="export PATH=\$PATH:\$HOME/.local/bin         && if [ \"\$(stat -c '%U' ${CONDA_INSTALL_PATH})\" != \"${USERNAME}\" ]; then             sudo chown -R ${USERNAME}:root ${CONDA_INSTALL_PATH};         fi         && . ${CONDA_INSTALL_PATH}/etc/profile.d/conda.sh         && conda activate base"     && echo "$SNIPPET" | tee -a /root/.bashrc >> /home/${USERNAME}/.bashrc     && echo "$SNIPPET" | tee -a /root/.zshrc >> /home/${USERNAME}/.zshrc     && find ${CONDA_INSTALL_PATH}/ -follow -type f -name '*.a' -delete     && find ${CONDA_INSTALL_PATH}/ -follow -type f -name '*.js.map' -delete     && ${CONDA_INSTALL_PATH}/bin/conda clean -afy     && su --login -c "${CONDA_INSTALL_PATH}/bin/pip install --no-cache-dir --upgrade azureml-sdk[${AZURE_ML_SDK_EXTRAS}]" ${USERNAME} 2>&1     && apt-get autoremove -y     && apt-get clean -y     && rm -rf /var/lib/apt/lists/*]: exit code: 100

jamescrowley avatar Aug 02 '22 13:08 jamescrowley

cc @sevillal I'm not sure if you've reviewed or used the AML dev container template at all, but wanted to loop you in in case you had any thoughts.

bamurtaugh avatar Sep 02 '22 21:09 bamurtaugh

Hey @bamurtaugh, I haven't worked on this template before. I tried it out and I was not able to repro on my local machine, from the logs it looks like it the repo to install docker engine is not registered.

@jamescrowley what docker version are you using?

sevillal avatar Sep 06 '22 17:09 sevillal