-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c9e613d
commit a09d6eb
Showing
1 changed file
with
18 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,15 @@ | ||
FROM ubuntu:20.04 AS ndt_base_ubuntu20 | ||
|
||
ENV TZ=Europe/Moscow | ||
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone | ||
|
||
ARG MOFED_VER=5.9-0.5.6.0 | ||
ARG MOFED_DIR=MLNX_OFED_LINUX-${MOFED_VER}-ubuntu20.04-x86_64 | ||
|
||
LABEL maintainer="[email protected]" | ||
ARG _ARCH=x86_64 | ||
ARG _DIST=ubuntu20.04 | ||
ARG _OFED_VER=5.9-0.5.6.0 | ||
ARG OFED_URL=http://nbu-nfs.mellanox.com/auto/sw/release/mlnx_ofed/MLNX_OFED/MLNX_OFED_LINUX-${_OFED_VER}/MLNX_OFED_LINUX-${_OFED_VER}-${_DIST}-${_ARCH}/DEBS | ||
ARG NDT_OFED_DEP="libibumad3 libibverbs1 ibverbs-providers " | ||
ARG BASE_PATH=/opt/ufm/ufm_plugin_ndt | ||
|
||
LABEL maintainer="[email protected]" | ||
ENV TZ=Europe/Moscow | ||
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone | ||
|
||
RUN apt-get update && apt upgrade -y && apt-get -y install supervisor python3 python3-pip rsyslog mc wget cron logrotate vim libcap2 curl sudo | ||
|
||
|
@@ -24,14 +25,15 @@ COPY config/ndt_httpd_proxy.conf config/ndt.conf config/ufm_plugin_ndt_httpd.con | |
|
||
RUN /ui_build.sh | ||
|
||
RUN echo "wget -q https://content.mellanox.com/ofed/MLNX_OFED-${MOFED_VER}/${MOFED_DIR}.tgz" | ||
# Install OFED | ||
RUN wget -q https://content.mellanox.com/ofed/MLNX_OFED-${MOFED_VER}/${MOFED_DIR}.tgz && \ | ||
tar xf ${MOFED_DIR}.tgz && \ | ||
rm -f ${MOFED_DIR}.tgz && \ | ||
cd ${MOFED_DIR} && \ | ||
./mlnxofedinstall --without-fw-update --user-space-only --skip-distro-check --skip-unsupported-devices-check --force && \ | ||
cd ../ && \ | ||
rm -rf ${MOFED_DIR} | ||
RUN echo "Download ibdiagnet (${NDT_OFED_DEP}}) from mofed (${_OFED_VER}}) repo" && \ | ||
mkdir /tmp/ofed_temp && pushd /tmp/ofed_temp && \ | ||
# mofed deb is not a proper repository so cannot be added as a repo but needs to be downloaded and installed manually \ | ||
for pkg in ${NDT_OFED_DEP}; do \ | ||
full_pkg_name=$(curl ${OFED_URL}/ 2>&1| sed -n "s/.*>\s*\(${pkg}_.*deb\)<.*/\1/p" ); \ | ||
curl ${OFED_URL}/${full_pkg_name} -O; \ | ||
done && \ | ||
apt-get install -y ./* && \ | ||
popd && \ | ||
rm -rf /tmp/ofed_temp | ||
|
||
CMD ["/usr/bin/supervisord", "-c", "/etc/supervisor/supervisord.conf"] |