forked from Mellanox/bfb-build
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Weitao Zhou <[email protected]>
- Loading branch information
Weitao Zhou
committed
Jun 19, 2023
1 parent
94519b9
commit f51dfee
Showing
5 changed files
with
54 additions
and
130 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,17 +1,20 @@ | ||
from --platform=linux/arm64 rockylinux:8.6.20227707 | ||
from --platform=linux/arm64 registry.openanolis.cn/openanolis/anolisos:8.6 | ||
ADD qemu-aarch64-static /usr/bin/ | ||
|
||
WORKDIR /root/workspace | ||
ADD install.sh . | ||
ADD create_bfb . | ||
ADD mlxbf-bootimages-3.9.3-12383.aarch64.rpm . | ||
ADD mlxbf-bootimages-@[email protected] . | ||
|
||
|
||
ENV RUN_FW_UPDATER=no | ||
|
||
RUN dnf install -y epel-release "dnf-command(config-manager)" && \ | ||
dnf config-manager --set-enabled powertools && \ | ||
RUN dnf install -y anolis-experimental-release epel-release "dnf-command(config-manager)" && \ | ||
dnf config-manager --set-enabled PowerTools && \ | ||
dnf config-manager --set-enabled Experimental && \ | ||
sed -i 's#$releasever#8.6#' /etc/yum.repos.d/Anolis* && \ | ||
dnf module enable -y ruby:3.0 && dnf config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo && \ | ||
dnf install --enablerepo=baseos -y passwd dracut-network dracut-tools dracut-squash bc bison flex \ | ||
dnf install --enablerepo=BaseOS -y passwd dracut-network dracut-tools dracut-squash bc bison flex \ | ||
pesign rsync re2c patchutils git annobin intltool dwarves groff \ | ||
kernel-rpm-macros libtool rpm-build rpm-sign automake meson cmake \ | ||
gcc-c++ cryptsetup ltrace lsof jq unzip sysstat nvme-cli uuid \ | ||
|
@@ -23,26 +26,38 @@ RUN dnf install -y epel-release "dnf-command(config-manager)" && \ | |
python3-Cython python3-sphinx python3-twisted glib2-devel python36-devel elfutils-devel \ | ||
binutils-devel pciutils-devel openssl-devel libnl3-devel selinux-policy-devel numactl-devel \ | ||
unbound-devel libpcap-devel tcl-devel valgrind-devel iptables-devel libdb-devel libmnl-devel \ | ||
dmidecode edac-utils ipmitool libiscsi libsysfs llvm-libs redhat-lsb-core redhat-lsb-submod-security \ | ||
dmidecode edac-utils ipmitool libiscsi libsysfs llvm-libs mstflint \ | ||
system-lsb-submod-security system-lsb-core \ | ||
docker-ce docker-ce-cli container-selinux containerd.io | ||
|
||
RUN dnf update -y | ||
|
||
RUN dnf config-manager --nogpgcheck --add-repo https://linux.mellanox.com/public/repo/doca/1.5.1/rockylinux8.6/aarch64/ | ||
|
||
RUN dnf install -y kernel-4.18.0-372.26.1.el8_6 \ | ||
kernel-core-4.18.0-372.26.1.el8_6 \ | ||
kernel-cross-headers-4.18.0-372.26.1.el8_6 \ | ||
kernel-devel-4.18.0-372.26.1.el8_6 \ | ||
kernel-headers-4.18.0-372.26.1.el8_6 \ | ||
kernel-modules-4.18.0-372.26.1.el8_6 \ | ||
kernel-modules-extra-4.18.0-372.26.1.el8_6 | ||
|
||
RUN dnf install --nogpgcheck -y doca-runtime doca-tools doca-sdk | ||
RUN dnf install -y kernel-5.10.134-13.an8 \ | ||
kernel-core-5.10.134-13.an8 \ | ||
kernel-devel-5.10.134-13.an8 \ | ||
kernel-headers-5.10.134-13.an8 \ | ||
kernel-modules-5.10.134-13.an8 \ | ||
kernel-modules-extra-5.10.134-13.an8 | ||
|
||
RUN wget https://www.mellanox.com/downloads/ofed/MLNX_OFED-@MLNX_OFED_VERSION@/MLNX_OFED_SRC-@[email protected] && \ | ||
tar xzf MLNX_OFED_SRC-@[email protected] && \ | ||
cd MLNX_OFED_SRC-@MLNX_OFED_VERSION@ && \ | ||
./install.pl -k 5.10.134-13.an8.aarch64 --kernel-sources /lib/modules/5.10.134-13.an8.aarch64/build \ | ||
--kernel-extra-args '--with-sf-cfg-drv --without-xdp --without-odp' \ | ||
--kernel-only --build-only && cd .. && \ | ||
find MLNX_OFED_SRC-@MLNX_OFED_VERSION@/RPMS -name '*rpm' -a ! -name '*debuginfo*rpm' -exec rpm -ihv '{}' \; | ||
|
||
RUN cd /tmp && wget -r -np -nH --cut-dirs=3 -R "index.html*" https://linux.mellanox.com/public/repo/bluefield/@VERSION@/extras/SRPMS/ | ||
RUN mkdir -p /tmp/@VERSION@/extras/{SPECS,RPMS,SOURCES,BUILD} && \ | ||
for p in /tmp/@VERSION@/extras/SRPMS/*.src.rpm; do rpmbuild --rebuild -D "debug_package %{nil}" -D "KVERSION 5.10.134-13.an8.aarch64" --define "_topdir /tmp/@VERSION@/extras" $p;done && \ | ||
rpm -ivh --force /tmp/@VERSION@/extras/RPMS/aarch64/*.rpm | ||
|
||
RUN dnf config-manager --add-repo https://linux.mellanox.com/public/repo/doca/2.0.2/rockylinux8.6/aarch64/ && \ | ||
dnf install --nogpgcheck -y doca-runtime-user doca-tools doca-sdk-user mft kmod-kernel-mft-mlnx | ||
|
||
RUN /usr/sbin/update-pciids || true | ||
RUN rpm -ihv --force mlxbf-bootimages-*.aarch64.rpm || true | ||
RUN rpm -ihv --force ${WORKDIR}/mlxbf-bootimages-*.aarch64.rpm || true | ||
|
||
RUN sed -i -e "s/signed/@IMAGE_TYPE@@CUSTOM_VERSION@/" /etc/mlnx-release | ||
RUN sed -i -e "s/RockyLinux/@IMAGE_TYPE@_@CUSTOM_VERSION@/" /etc/mlnx-release | ||
|
||
CMD ["/root/workspace/create_bfb", "-k", "4.18.0-372.26.1.el8_6.aarch64"] | ||
CMD ["/root/workspace/create_bfb", "-k", "5.10.134-13.an8.aarch64"] |
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
This file was deleted.
Oops, something went wrong.
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
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