From f07e0c5a9be3bf314ed29c06fad67f558e0bd833 Mon Sep 17 00:00:00 2001 From: Dave Dykstra <2129743+DrDaveD@users.noreply.github.com> Date: Fri, 12 Jul 2024 15:05:41 -0500 Subject: [PATCH] remove many references to el7, centos, and yum Signed-off-by: Dave Dykstra <2129743+DrDaveD@users.noreply.github.com> --- appendix.rst | 22 +++++++++++----------- definition_files.rst | 12 ++++++------ fakeroot.rst | 10 +++++----- introduction.rst | 4 ++-- quick_start.rst | 2 +- running_services.rst | 2 +- security_options.rst | 4 ++-- 7 files changed, 28 insertions(+), 28 deletions(-) diff --git a/appendix.rst b/appendix.rst index 927c681d..f607dbfd 100755 --- a/appendix.rst +++ b/appendix.rst @@ -588,7 +588,7 @@ Docker images are comprised of layers that are assembled at runtime to create an image. You can use Docker layers to create a base image, and then add your own custom software. For example, you might use Docker's Ubuntu image layers to create an Ubuntu {Project} container. You -could do the same with CentOS, Debian, Arch, Suse, Alpine, BusyBox, etc. +could do the same with Fedora, Debian, Arch, Suse, Alpine, BusyBox, etc. Or maybe you want a container that already has software installed. For instance, maybe you want to build a container that uses CUDA and cuDNN @@ -809,13 +809,13 @@ the new image during bootstrap. .. _sec:build-yum: -This module allows you to build a Red Hat/CentOS/Scientific Linux style -container from a mirror URI. +This module allows you to build a Red Hat style +container from a mirror URI based on yum or dnf. Overview -------- -Use the ``yum`` module to specify a base for a CentOS-like container. +Use the ``yum`` module to specify a base for a RHEL-like container. You must also specify the URI for the mirror you would like to use. Keywords @@ -830,7 +830,7 @@ module to use. .. code:: {command} - OSVersion: 7 + OSVersion: 9 The OSVersion keyword is optional. It specifies the OS version you would like to use. It is only required if you have specified a %{OSVERSION} @@ -838,7 +838,7 @@ variable in the ``MirrorURL`` keyword. .. code:: {command} - MirrorURL: http://mirror.centos.org/centos-%{OSVERSION}/%{OSVERSION}/os/$basearch/ + MirrorURL: http://repo.almalinux.org/almalinux/%{OSVERSION}/BaseOS/x86_64/os The MirrorURL keyword is mandatory. It specifies the URI to use as a mirror to download the OS. If you define the ``OSVersion`` keyword, then @@ -846,13 +846,13 @@ you can use it in the URI as in the example above. .. code:: {command} - Include: yum + Include: dnf The Include keyword is optional. It allows you to install additional packages into the core operating system. It is a best practice to supply only the bare essentials such that the ``%post`` section has what it needs to properly complete the build. One common package you may want to -install when using the ``yum`` build module is YUM itself. +install when using the ``yum`` build module is YUM or DNF itself. Notes ----- @@ -864,7 +864,7 @@ system. If the RPM implementation inside the container is not compatible with the RPM database that was used to create the container, RPM and YUM commands inside the container may fail. This issue can be easily demonstrated by bootstrapping an older RHEL compatible image by a newer -one (e.g. bootstrap a Centos 6 container from a Centos 7 host). +one (e.g. bootstrap a RHEL 8 container from a RHEL 9 host). In order to use the ``yum`` build module, you must have ``yum`` installed on your system. It may seem counter-intuitive to install YUM @@ -939,11 +939,11 @@ like so: $ sudo apt-get update && sudo apt-get install debootstrap -On CentOS you can install it from the epel repos like so: +On RHEL you can install it from the epel repos like so: .. code:: - $ sudo yum update && sudo yum install epel-release && sudo yum install debootstrap.noarch + $ sudo dnf update && sudo dnf install epel-release && sudo dnf install debootstrap.noarch .. _build-arch: diff --git a/definition_files.rst b/definition_files.rst index f2e1c159..c8f43125 100755 --- a/definition_files.rst +++ b/definition_files.rst @@ -68,7 +68,7 @@ that uses the ``From`` keyword to build a Debian container: .. code:: {command} Bootstrap: docker - From: debian:7 + From: debian:10 A def file that uses an official mirror to install CentOS 7 might look like this: @@ -76,9 +76,9 @@ like this: .. code:: {command} Bootstrap: yum - OSVersion: 7 - MirrorURL: http://mirror.centos.org/centos-%{OSVERSION}/%{OSVERSION}/os/$basearch/ - Include: yum + OSVersion: 9 + MirrorURL: http://repo.almalinux.org/almalinux/%{OSVERSION}/BaseOS/x86_64/os + Include: dnf Each bootstrap agent enables its own options and keywords, which you can read about, and see examples of, in the :ref:`appendix `. @@ -97,8 +97,8 @@ Other bootstrap agents - :ref:`library ` (images hosted on Library API Registries) - :ref:`shub ` (images hosted on Singularity Hub) -- :ref:`yum ` (yum-based systems such as CentOS and - Scientific Linux) +- :ref:`yum ` (yum- or dnf- based systems such as RHEL and + its derivatives) - :ref:`debootstrap ` (apt-based systems such as Debian and Ubuntu) - oci (bundle compliant with OCI Image Specification) diff --git a/fakeroot.rst b/fakeroot.rst index e976a6f4..d0027428 100644 --- a/fakeroot.rst +++ b/fakeroot.rst @@ -207,7 +207,7 @@ Add package to a writable overlay .. code:: mkdir /tmp/test.overlay - {command} exec --fakeroot --overlay /tmp/test.overlay /tmp/test.sif yum -y install openssh + {command} exec --fakeroot --overlay /tmp/test.overlay /tmp/test.sif dnf -y install openssh Ping from container: -------------------- @@ -250,13 +250,13 @@ containing this: .. code:: {command} Bootstrap: docker - From: docker://centos:7 + From: docker://rockylinux:8 %post - yum install -y epel-release - yum install -y fakeroot + dnf install -y epel-release + dnf install -y fakeroot fakeroot bash -c ' - yum install -y openssh + dnf install -y openssh ' then build with diff --git a/introduction.rst b/introduction.rst index a786a4d6..50c20a74 100644 --- a/introduction.rst +++ b/introduction.rst @@ -53,7 +53,7 @@ most people are most familiar with. It is where applications, libraries and system services run. Traditionally you use an operating system that has a fixed combination -of kernel and user space. If you have access to a machine running CentOS +of kernel and user space. If you have access to a machine running RHEL then you cannot install software that was packaged for Ubuntu on it, because the user space of these distributions is not compatible. It can also be very difficult to install multiple versions of the same @@ -63,7 +63,7 @@ workflows over time. Containers change the user space into a swappable component. This means that the entire user space portion of a Linux operating system, including programs, custom configurations, and environment can be -independent of whether your system is running CentOS, Fedora etc., +independent of whether your system is running RHEL, Fedora etc., underneath. {AProject} container packages up whatever you need into a single, verifiable file. diff --git a/quick_start.rst b/quick_start.rst index 42016e10..0b2245fc 100644 --- a/quick_start.rst +++ b/quick_start.rst @@ -540,7 +540,7 @@ recommended that you build a SIF file using {aProject} definition file. This also makes it easy to add files, environment variables, and install custom software. You can start with base images from Docker Hub and use images directly from official repositories such as Ubuntu, Debian, -CentOS, Arch, and BusyBox. +Fedora, Arch, and BusyBox. A definition file has a header and a body. The header determines the base container to begin with, and the body is further divided into diff --git a/running_services.rst b/running_services.rst index 59d48ae8..f053622b 100644 --- a/running_services.rst +++ b/running_services.rst @@ -37,7 +37,7 @@ typically install the package for the web server and then instruct systemd .. code:: - $ sudo yum install nginx + $ sudo dnf install nginx $ sudo systemctl enable --now nginx If you were to attempt this in a container, it's likely that it will not work as diff --git a/security_options.rst b/security_options.rst index cbc13860..c32a240b 100644 --- a/security_options.rst +++ b/security_options.rst @@ -159,7 +159,7 @@ file and enter the container with full capabilities using the .. code:: - $ sudo {command} exec --keep-privs docker://centos:7 ping -c 1 8.8.8.8 + $ sudo {command} exec --keep-privs docker://rockylinux:8 ping -c 1 8.8.8.8 PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data. 64 bytes from 8.8.8.8: icmp_seq=1 ttl=128 time=18.8 ms @@ -179,7 +179,7 @@ inside the container: .. code:: - $ sudo {command} exec --drop-caps CAP_NET_RAW docker://centos:7 ping -c 1 8.8.8.8 + $ sudo {command} exec --drop-caps CAP_NET_RAW docker://rockylinux:8 ping -c 1 8.8.8.8 ping: socket: Operation not permitted The ``drop-caps`` option will also accept the case insensitive keyword