mirror of
https://gitlab.eurecom.fr/oai/openairinterface5g.git
synced 2026-07-13 04:30:28 +00:00
- This is to overcome the issue of pull rate limits from DockerHub
- Make Ubuntu base image configurable via build-arg
93 lines
3.2 KiB
Docker
93 lines
3.2 KiB
Docker
#/*
|
|
# * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
|
|
# * contributor license agreements. See the NOTICE file distributed with
|
|
# * this work for additional information regarding copyright ownership.
|
|
# * The OpenAirInterface Software Alliance licenses this file to You under
|
|
# * the OAI Public License, Version 1.1 (the "License"); you may not use this file
|
|
# * except in compliance with the License.
|
|
# * You may obtain a copy of the License at
|
|
# *
|
|
# * http://www.openairinterface.org/?page_id=698
|
|
# *
|
|
# * Unless required by applicable law or agreed to in writing, software
|
|
# * distributed under the License is distributed on an "AS IS" BASIS,
|
|
# * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
# * See the License for the specific language governing permissions and
|
|
# * limitations under the License.
|
|
# *-------------------------------------------------------------------------------
|
|
# * For more information about the OpenAirInterface (OAI) Software Alliance:
|
|
# * contact@openairinterface.org
|
|
# */
|
|
ARG UBUNTU_IMAGE=ubuntu:noble
|
|
FROM ran-base:latest AS ran-base
|
|
|
|
FROM ran-build-fhi72:latest AS ran-build
|
|
|
|
#start from scratch for target executable
|
|
FROM ${UBUNTU_IMAGE} AS oai-nr-oru
|
|
ARG BUILD_OPTION
|
|
ENV DEBIAN_FRONTEND=noninteractive
|
|
ENV TZ=Europe
|
|
|
|
RUN apt-get update && \
|
|
apt-get upgrade --yes && \
|
|
apt-get install --yes \
|
|
software-properties-common \
|
|
procps \
|
|
pkg-config \
|
|
libsctp1 \
|
|
tzdata \
|
|
libconfig9 \
|
|
openssl \
|
|
net-tools \
|
|
iperf \
|
|
iproute2 \
|
|
iputils-ping \
|
|
gdb \
|
|
pciutils \
|
|
libpcap-dev \
|
|
xz-utils \
|
|
libnuma-dev \
|
|
libyaml-cpp-dev && \
|
|
rm -rf /var/lib/apt/lists/*
|
|
|
|
WORKDIR /opt/nr-oru/bin
|
|
COPY --from=ran-build \
|
|
/oai-ran/cmake_targets/ran_build/build/nr-oru ./
|
|
COPY ./docker/scripts/nr_oru_entrypoint.sh ./entrypoint.sh
|
|
|
|
COPY --from=ran-build \
|
|
/oai-ran/cmake_targets/ran_build/build/liboai_transpro.so \
|
|
/oai-ran/cmake_targets/ran_build/build/libcoding.so \
|
|
/oai-ran/cmake_targets/ran_build/build/libparams_libconfig.so \
|
|
/oai-ran/cmake_targets/ran_build/build/libdfts.so \
|
|
/oai-ran/cmake_targets/ran_build/build/libldpc*.so \
|
|
/oai-ran/cmake_targets/ran_build/build/libparams_yaml.so \
|
|
/usr/local/lib/
|
|
|
|
## Libxran library
|
|
COPY --from=ran-build \
|
|
/opt/phy/fhi_lib/lib/build/libxran.so \
|
|
/opt/phy/fhi_lib/lib/build/
|
|
|
|
## Copy all DPDK libraries as liboran_fhlib_5g.so require most of them
|
|
COPY --from=ran-build /usr/local/lib/x86_64-linux-gnu /usr/local/lib/x86_64-linux-gnu/
|
|
|
|
RUN ldconfig && \
|
|
echo "---- ldd on nr-oru ----" && \
|
|
ldd /opt/nr-oru/bin/nr-oru && \
|
|
echo "---- ldd on shared libraries ----" && \
|
|
ldd /usr/local/lib/liboai_transpro.so \
|
|
/usr/local/lib/libcoding.so \
|
|
/usr/local/lib/libparams_libconfig.so \
|
|
/usr/local/lib/libdfts.so \
|
|
/usr/local/lib/libldpc*.so \
|
|
/opt/phy/fhi_lib/lib/build/libxran.so
|
|
|
|
WORKDIR /opt/nr-oru
|
|
|
|
COPY --from=ran-base /usr/local/bin/yq /usr/local/bin/yq
|
|
COPY --from=ran-base /tini /tini
|
|
ENTRYPOINT ["/tini", "-v", "--", "/opt/nr-oru/bin/entrypoint.sh"]
|
|
CMD ["/opt/nr-oru/bin/nr-oru"]
|