From 5b53662b9e221b0591486f6fd795f0985a65bab6 Mon Sep 17 00:00:00 2001 From: Jonathon Anderson Date: Thu, 14 Dec 2023 10:33:19 -0700 Subject: [PATCH] New example definition file, rockylinux-9.2-mofed Signed-off-by: Jonathon Anderson --- README.md | 1 + examples/README.md | 9 ++++++++ examples/rockylinux-9.2-mofed/Containerfile | 25 +++++++++++++++++++++ examples/rockylinux-9.2-mofed/README.md | 16 +++++++++++++ 4 files changed, 51 insertions(+) create mode 100644 examples/README.md create mode 100644 examples/rockylinux-9.2-mofed/Containerfile create mode 100644 examples/rockylinux-9.2-mofed/README.md diff --git a/README.md b/README.md index 94a1e36..162e4b7 100644 --- a/README.md +++ b/README.md @@ -20,6 +20,7 @@ Additional container definitions that are not actively built and published, but may still be useful. * [Rocky Linux 9 with SELinux][examples/rockylinux-9-selinux] +* [Rocky Linux 9.2 with Mellanox OFED][examples/rockylinux-9.2-mofed] You can build any of these (or the other container definitions) locally for import into Warewulf v4. diff --git a/examples/README.md b/examples/README.md new file mode 100644 index 0000000..60dfed9 --- /dev/null +++ b/examples/README.md @@ -0,0 +1,9 @@ +# Example container definitions + +The container definitions in the directory aren't built as containers published +by Warewulf for some reason. +Typical reasons may include: + +* The resultant container would be too large. +* The definition is too specific to be broadly useful, and covering a wide enough set of versions would be impractical. +* The definition uses software that may not be redistributed. diff --git a/examples/rockylinux-9.2-mofed/Containerfile b/examples/rockylinux-9.2-mofed/Containerfile new file mode 100644 index 0000000..5577526 --- /dev/null +++ b/examples/rockylinux-9.2-mofed/Containerfile @@ -0,0 +1,25 @@ +FROM ghcr.io/hpcng/warewulf-rockylinux:9.2 + +RUN dnf -y install \ + gcc \ + patch \ + libtool \ + lsof \ + kernel-rpm-macros \ + make \ + rpm-build \ + gdb-headless \ + python3-devel \ + elfutils-libelf-devel \ + gcc-gfortran \ + tk \ + kernel-{core,devel,headers,modules-extra} \ + perl-sigtrap \ + numactl-libs \ + tcsh \ + && dnf -y remove $(dnf repoquery --installonly --latest-limit=-1 -q) \ + && dnf clean all + +RUN (cd /tmp && tar -xf /mnt/MLNX_OFED_LINUX-5.8-3.0.7.0-rhel9.2-x86_64.tgz) \ + && (cd /tmp/MLNX_OFED_LINUX-5.8-3.0.7.0-rhel9.2-x86_64 && ./mlnxofedinstall --distro rhel9.2 --skip-repo --kernel $(rpm -q kernel-core --qf '%{version}-%{release}.%{arch}\n' | tail -n 1) --add-kernel-support --hpc) \ + && rm -rf /tmp/MLNX_OFED_LINUX* diff --git a/examples/rockylinux-9.2-mofed/README.md b/examples/rockylinux-9.2-mofed/README.md new file mode 100644 index 0000000..3f19547 --- /dev/null +++ b/examples/rockylinux-9.2-mofed/README.md @@ -0,0 +1,16 @@ +# Rocky Linux with the Mellanox OFED + +This container definition demonstrates building a Rocky Linux based container +incorporating the Mellanox OFED for InfiniBand support. + +This definition requires that the [Mellanox OFED .tgz][1] for the desired +version be placed in the `rockylinux-mofed` directory. + +[1]: https://network.nvidia.com/products/infiniband-drivers/linux/mlnx_ofed/ + +With that in place, the container may be built with Podman. + +```shell + +podman build --volume $PWD:/mnt:ro --file Containerfile . +```