Skip to content

Commit 11ce8f4

Browse files
[nrfconnect] Update nRF Connect SDK version in Docekr to 3.0.0 (project-chip#39702)
Regular update of nRF Connect SDK to 3.0.0 version. Signed-off-by: Arkadiusz Balys <[email protected]>
1 parent 1b8666c commit 11ce8f4

File tree

2 files changed

+35
-44
lines changed
  • integrations/docker/images

2 files changed

+35
-44
lines changed
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
143 : Upgrading Silabs Docker - SiSDK 2025.6.0, Wiseconnect SDK 3.5.0 and WC BT 2.12.0
1+
144 : [nrfconnect] Update nRF Connect SDK version to 3.0.0.
Lines changed: 34 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,77 +1,68 @@
11
ARG VERSION=1
22

3-
# ==================================================
4-
# Temporary image for SDK and dependencies download
5-
# ==================================================
6-
73
FROM ghcr.io/project-chip/chip-build:${VERSION} as build
8-
LABEL org.opencontainers.image.source https://github.com/project-chip/connectedhomeip
9-
# Compatible Nordic Connect SDK revision.
10-
ARG NCS_REVISION=v2.9.0
114

12-
# Requirements to clone SDKs in temporary container
5+
# Compatible Nordic Connect SDK revision and required tools versions
6+
ARG NCS_REVISION=v3.0.0
7+
ARG JLINK_VERSION="JLink_Linux_V818_x86_64"
8+
ARG WEST_VERSION=1.2.0
9+
ARG CMAKE_VERSION=3.25.0
10+
11+
# Requirements to clone SDKs
1312
RUN set -x \
1413
&& apt-get update \
1514
&& DEBIAN_FRONTEND=noninteractive apt-get install -fy --no-install-recommends \
1615
xz-utils \
16+
&& apt-get clean \
17+
&& rm -rf /var/lib/apt/lists/ \
1718
&& : # last line
1819

1920
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
2021
WORKDIR /opt/NordicSemiconductor/nRF5_tools
2122
RUN set -x \
22-
&& curl --location https://nsscprodmedia.blob.core.windows.net/prod/software-and-other-downloads/desktop-software/nrf-command-line-tools/sw/versions-10-x-x/10-24-2/nrf-command-line-tools-10.24.2_linux-amd64.tar.gz \
23-
| tar zxvf - \
24-
&& tar xvf JLink_Linux_V794e_x86_64.tgz \
25-
&& rm JLink_Linux_V794e_x86_64.* \
26-
&& curl --location https://github.com/zephyrproject-rtos/sdk-ng/releases/download/v0.17.0/zephyr-sdk-0.17.0_linux-x86_64_minimal.tar.xz --output zephyr-sdk-0.17.0_linux-x86_64_minimal.tar.xz \
27-
&& tar xvf zephyr-sdk-0.17.0_linux-x86_64_minimal.tar.xz \
28-
&& rm -rf zephyr-sdk-0.17.0_linux-x86_64_minimal.tar.xz \
29-
&& zephyr-sdk-0.17.0/setup.sh -t arm-zephyr-eabi \
23+
# Get JLink
24+
&& curl -d "accept_license_agreement=accepted&submit=Download+software" -X POST -O "https://www.segger.com/downloads/jlink/${JLINK_VERSION}.tgz" \
25+
&& tar xvf ${JLINK_VERSION}.tgz \
26+
&& rm ${JLINK_VERSION}.* \
27+
# Get nRF Util
28+
&& curl --location https://files.nordicsemi.com/artifactory/swtools/external/nrfutil/executables/x86_64-unknown-linux-gnu/nrfutil -o nrfutil \
29+
&& chmod +x ./nrfutil \
30+
&& ./nrfutil self-upgrade \
31+
&& ./nrfutil install device \
32+
&& ./nrfutil install sdk-manager \
33+
# Download nRF Connect toolchain
34+
&& ./nrfutil sdk-manager toolchain install --ncs-version "$NCS_REVISION" --install-dir ./zephyr-sdk \
3035
&& : # last line
3136

3237
WORKDIR /opt/NordicSemiconductor/nrfconnect
3338
RUN set -x \
34-
&& python3 -m pip install --break-system-packages -U --no-cache-dir west==1.2.0 \
39+
&& python3 -m pip install --break-system-packages -U --no-cache-dir west==${WEST_VERSION} \
3540
&& west init -m https://github.com/nrfconnect/sdk-nrf --mr "$NCS_REVISION" \
3641
&& west config update.narrow true \
3742
&& west config update.fetch smart \
3843
&& west update -o=--depth=1 -n -f smart \
3944
&& : # last line
4045

41-
# ==================================================
42-
# nRF Connect SDK final image
43-
# ==================================================
44-
45-
FROM ghcr.io/project-chip/chip-build:${VERSION}
46-
4746
# Tools for building, flashing and accessing device logs
4847
RUN set -x \
4948
&& apt-get update \
50-
&& apt-get install --no-install-recommends -fy device-tree-compiler gcc-multilib g++-multilib \
49+
&& apt-get install --no-install-recommends -fy device-tree-compiler gcc-multilib g++-multilib libusb-1.0-0 \
5150
&& apt-get clean \
5251
&& rm -rf /var/lib/apt/lists/ \
5352
&& : # last line
5453

55-
COPY --from=build /opt/NordicSemiconductor/nRF5_tools/ /opt/NordicSemiconductor/nRF5_tools/
56-
COPY --from=build /opt/NordicSemiconductor/nrfconnect/ /opt/NordicSemiconductor/nrfconnect/
57-
58-
RUN set -x \
59-
# python3-yaml and python3-numpy packages conflict with nRF Python requirements
60-
&& (apt-get remove -fy python3-yaml python3-numpy && apt-get autoremove || exit 0) \
61-
&& python3 -m pip install --break-system-packages -U --no-cache-dir cmake==3.25.0 \
62-
&& python3 -m pip install --break-system-packages --no-cache-dir -r /opt/NordicSemiconductor/nrfconnect/zephyr/scripts/requirements-base.txt \
63-
&& python3 -m pip install --break-system-packages --no-cache-dir -r /opt/NordicSemiconductor/nrfconnect/nrf/scripts/requirements-build.txt \
64-
&& python3 -m pip install --break-system-packages --no-cache-dir -r /opt/NordicSemiconductor/nrfconnect/bootloader/mcuboot/scripts/requirements.txt \
65-
&& python3 -m pip install --break-system-packages --no-cache-dir -r /opt/NordicSemiconductor/nrfconnect/modules/lib/matter/scripts/setup/requirements.nrfconnect.txt \
66-
&& : # last line
67-
6854
ENV NRF5_TOOLS_ROOT=/opt/NordicSemiconductor/nRF5_tools
69-
ENV PATH=${NRF5_TOOLS_ROOT}/JLink_Linux_V794e_x86_64:${PATH}
70-
ENV PATH=${NRF5_TOOLS_ROOT}/nrf-command-line-tools/bin:${PATH}
71-
ENV LD_LIBRARY_PATH=${NRF5_TOOLS_ROOT}/JLink_Linux_V794e_x86_64:${LD_LIBRARY_PATH}
55+
ENV PATH=${NRF5_TOOLS_ROOT}:$PATH
56+
ENV PATH=${NRF5_TOOLS_ROOT}/${JLINK_VERSION}:${PATH}
7257
ENV LC_ALL=C.UTF-8
7358
ENV LANG=C.UTF-8
7459
ENV ZEPHYR_BASE=/opt/NordicSemiconductor/nrfconnect/zephyr
75-
ENV ZEPHYR_SDK_INSTALL_DIR=${NRF5_TOOLS_ROOT}/zephyr-sdk-0.17.0
76-
ENV ZEPHYR_TOOLCHAIN_VARIANT=zephyr
77-
ENV ZEPHYR_TOOLCHAIN_PATH=${ZEPHYR_SDK_INSTALL_DIR}/arm-zephyr-eabi
60+
61+
# Set up Zephyr SDK environment variables
62+
RUN set -x \
63+
# Setup Zephyr SDK environment variables
64+
# Do not use the nrfconnect python environment because the python environment should be created by bootstrap.sh
65+
&& nrfutil sdk-manager toolchain env --as-script --ncs-version "$NCS_REVISION" --install-dir ${NRF5_TOOLS_ROOT}/zephyr-sdk | grep -v "PYTHONHOME\|PYTHONPATH" | tee -a /root/.bashrc \
66+
# Remove redundant directory created by nrfutil
67+
&& rm -rf ${NRF5_TOOLS_ROOT}/zephyr-sdk/downloads \
68+
&& : # last line

0 commit comments

Comments
 (0)