Installing docker for edge-impulse-nordic fails

I am now running Ubuntu 22.04.

The following command fails for me:

sudo docker build -t edge-impulse-nordic .

The error is:

Dockerfile:38
--------------------
  36 |     RUN mkdir /ncs
  37 |     RUN cd /ncs && west init -m github.com/.../sdk-nrf --mr v2.4.0
  38 | >>> RUN cd /ncs && west update
  39 |     RUN cd /ncs && west zephyr-export
  40 |     RUN pip3 install -r /ncs/zephyr/scripts/requirements.txt
--------------------
ERROR: failed to solve: process "/bin/sh -c cd /ncs && west update" did not complete successfully: exit code: 128

I tried this many times.

  • Keep having issues with this docker installation.

    tony@tony-HP-Laptop:~/nordic/firmware-nordic-thingy53$ sudo docker build -t edge-impulse-nordic .
    [+] Building 1429.1s (14/16)                                                                                         docker:default
     => [internal] load build definition from Dockerfile                                                                           0.0s
     => => transferring dockerfile: 1.67kB                                                                                         0.0s
     => [internal] load metadata for docker.io/library/ubuntu:20.04                                                                0.7s
     => [internal] load .dockerignore                                                                                              0.0s
     => => transferring context: 80B                                                                                               0.0s
     => [ 1/13] FROM docker.io/library/ubuntu:20.04@sha256:fa17826afb526a9fc7250e0fbcbfd18d03fe7a54849472f86879d8bf562c629e        0.0s
     => CACHED [ 2/13] WORKDIR /app                                                                                                0.0s
     => CACHED [ 3/13] RUN apt update && apt install -y --no-install-recommends git ninja-build gperf     ccache dfu-util device-  0.0s
     => CACHED [ 4/13] RUN if [ $(uname -m) = "x86_64" ]; then export ARCH=x86_64; else export ARCH=aarch64; fi &&     mkdir -p /  0.0s
     => CACHED [ 5/13] RUN if [ $(uname -m) = "x86_64" ]; then export ARCH=x86_64; else export ARCH=aarch64; fi &&     cd /opt &&  0.0s
     => CACHED [ 6/13] RUN python3 -m pip install pip==21.2.4                                                                      0.0s
     => CACHED [ 7/13] RUN pip3 install west==1.0.0                                                                                0.0s
     => CACHED [ 8/13] RUN pip3 install ecdsa==0.17.0                                                                              0.0s
     => CACHED [ 9/13] RUN mkdir /ncs                                                                                              0.0s
     => CACHED [10/13] RUN cd /ncs && west init -m github.com/.../sdk-nrf --mr v2.4.0                               0.0s
     => CANCELED [11/13] RUN cd /ncs && west update                                                                             1428.4s
    ERROR: failed to solve: Canceled: context canceled     

  • Hi Tony

    Two questions: 

    1. Is there a specific reason to why you want to use NCS 2.4? As 2.7 is out I would recommend using it

    2. Have you tested https://github.com/NordicPlayground/nrf-docker

    Regards

    Runar

  • Hi,

    I do not have specific reasons. That is just happening out of the box with my checkout for github. I will dive a bit deeper.

    I will try the docker code that you mentioned.

  • I am on main branch:

    tony@tony-HP-Laptop:~/nordic/firmware-nordic-thingy53$ git branch
    * main

  • Getting errors with nrf-docker as well.

    310.9 raise MalformedConfig('local configuration file not found')
    310.9 west.configuration.MalformedConfig: local configuration file not found
    310.9 Error: Launched process exited with non-zero status: 1
    ------

    1 warning found (use docker --debug to expand):
    - FromAsCasing: 'as' and 'FROM' keywords' casing do not match (line 1)
    Dockerfile:80
    --------------------
    79 | SHELL ["nrfutil","toolchain-manager","launch","/bin/bash","--","-c"]
    80 | >>> RUN <<EOT
    81 | >>> west init -m github.com/.../sdk-nrf --mr ${sdk_nrf_branch} .
    82 | >>> if [[ $sdk_nrf_commit =~ "^[a-fA-F0-9]{32}$" ]]; then
    83 | >>> git checkout ${sdk_nrf_commit};
    84 | >>> fi
    85 | >>> west update --narrow -o=--depth=1
    86 | >>> EOT
    87 |
    --------------------
    ERROR: failed to solve: process "nrfutil toolchain-manager launch /bin/bash -- -c west init -m github.com/.../sdk-nrf --mr ${sdk_nrf_branch} .\n if [[ $sdk_nrf_commit =~ \"^[a-fA-F0-9]{32}$\" ]]; then\n git checkout ${sdk_nrf_commit};\n fi\n west update --narrow -o=--depth=1\n" did not complete successfully: exit code: 1

Related