diff --git a/docs/use-cases/using-Intel-QAT-and-kata.md b/docs/use-cases/using-Intel-QAT-and-kata.md index 8482b67932..d4150a3adb 100644 --- a/docs/use-cases/using-Intel-QAT-and-kata.md +++ b/docs/use-cases/using-Intel-QAT-and-kata.md @@ -235,7 +235,7 @@ then [Kata-deploy](https://github.com/kata-containers/kata-containers/tree/main/ is use to install Kata. This will make sure that the correct `agent` version is installed into the rootfs in the steps below. -The following instructions use Debian as the root filesystem with systemd as +The following instructions use Ubuntu as the root filesystem with systemd as the init and will add in the `kmod` binary, which is not a standard binary in a Kata rootfs image. The `kmod` binary is necessary to load the IntelĀ® QAT kernel modules when the virtual machine rootfs boots. @@ -257,7 +257,7 @@ $ cd $GOPATH $ export AGENT_VERSION=$(kata-runtime version | head -n 1 | grep -o "[0-9.]\+") $ cd ${OSBUILDER}/rootfs-builder $ sudo rm -rf ${ROOTFS_DIR} -$ script -fec 'sudo -E GOPATH=$GOPATH USE_DOCKER=true SECCOMP=no ./rootfs.sh debian' +$ script -fec 'sudo -E GOPATH=$GOPATH USE_DOCKER=true SECCOMP=no ./rootfs.sh ubuntu' ``` ### Compile IntelĀ® QAT drivers for Kata Containers kernel and add to Kata Containers rootfs diff --git a/src/runtime/pkg/katatestutils/constraints_test.go b/src/runtime/pkg/katatestutils/constraints_test.go index 9444fe8e02..5513b26fd5 100644 --- a/src/runtime/pkg/katatestutils/constraints_test.go +++ b/src/runtime/pkg/katatestutils/constraints_test.go @@ -43,7 +43,6 @@ type testDataDistro struct { var distros = []string{ "centos", "clear-linux-os", - "debian", "fedora", "opensuse", "rhel", diff --git a/tools/osbuilder/dockerfiles/QAT/Dockerfile b/tools/osbuilder/dockerfiles/QAT/Dockerfile index 5b70ca5300..c2e37f97d8 100644 --- a/tools/osbuilder/dockerfiles/QAT/Dockerfile +++ b/tools/osbuilder/dockerfiles/QAT/Dockerfile @@ -16,7 +16,7 @@ ENV QAT_DRIVER_URL "https://downloadmirror.intel.com/649693/${QAT_DRIVER_VER}" ENV QAT_CONFIGURE_OPTIONS "--enable-icp-sriov=guest" ENV KATA_REPO_VERSION "main" ENV AGENT_VERSION "" -ENV ROOTFS_OS "debian" +ENV ROOTFS_OS "ubuntu" ENV OUTPUT_DIR "/output" RUN dnf install -y \ diff --git a/tools/osbuilder/dockerfiles/QAT/README.md b/tools/osbuilder/dockerfiles/QAT/README.md index 457446b867..370eceb5e0 100644 --- a/tools/osbuilder/dockerfiles/QAT/README.md +++ b/tools/osbuilder/dockerfiles/QAT/README.md @@ -10,7 +10,6 @@ to use. The following rootfs OS's have been tested with this Dockerfile. * CentOS * Clear Linux -* Debian * Fedora * SUSE * Ubuntu @@ -75,7 +74,7 @@ latest stable version of Kata Containers. | `QAT_CONFIGURE_OPTIONS` | `configure` options for QAT driver | `--enable-icp-sriov=guest` | | `QAT_DRIVER_URL` | URL to curl QAT driver from | `https://01.org/sites/default/files/downloads/${QAT_DRIVER_VER}` | | `QAT_DRIVER_VER` | QAT driver version to use | `qat1.7.l.4.9.0-00008.tar.gz` | -| `ROOTFS_OS` | Operating system to use for the rootfs | `debian` | +| `ROOTFS_OS` | Operating system to use for the rootfs | `ubuntu` | Variables can be set on the `docker run` commandline, for example: diff --git a/tools/osbuilder/dockerfiles/QAT/run.sh b/tools/osbuilder/dockerfiles/QAT/run.sh index 88909bb563..c5db4f3623 100755 --- a/tools/osbuilder/dockerfiles/QAT/run.sh +++ b/tools/osbuilder/dockerfiles/QAT/run.sh @@ -71,7 +71,7 @@ build_rootfs() # This should only be done for Ubuntu and Debian based OS's. Other OS # distributions had issues if building the rootfs from /proc - if [ "${ROOTFS_OS}" == "debian" ] || [ "${ROOTFS_OS}" == "ubuntu" ]; then + if [ "${ROOTFS_OS}" == "ubuntu" ]; then cd /proc fi /bin/echo -e "\n\e[1;42mDownload ${ROOTFS_OS} based rootfs\e[0m" diff --git a/tools/osbuilder/rootfs-builder/debian/Dockerfile-aarch64.in b/tools/osbuilder/rootfs-builder/debian/Dockerfile-aarch64.in deleted file mode 100644 index 4395913f9a..0000000000 --- a/tools/osbuilder/rootfs-builder/debian/Dockerfile-aarch64.in +++ /dev/null @@ -1,34 +0,0 @@ -# -# Copyright (c) 2020 ARM Limited -# -# SPDX-License-Identifier: Apache-2.0 - -ARG IMAGE_REGISTRY=docker.io -# NOTE: OS_VERSION is set according to config.sh -FROM ${IMAGE_REGISTRY}/debian:@OS_VERSION@ - -# RUN commands -RUN apt-get update && apt-get install -y \ - autoconf \ - automake \ - binutils \ - build-essential \ - chrony \ - coreutils \ - curl \ - debianutils \ - debootstrap \ - g++ \ - gcc \ - git \ - libc-dev \ - libstdc++-6-dev \ - m4 \ - make \ - sed \ - systemd \ - tar \ - vim -# This will install the proper packages to build Kata components -@INSTALL_MUSL@ -@INSTALL_RUST@ diff --git a/tools/osbuilder/rootfs-builder/debian/Dockerfile.in b/tools/osbuilder/rootfs-builder/debian/Dockerfile.in deleted file mode 100644 index 489940d447..0000000000 --- a/tools/osbuilder/rootfs-builder/debian/Dockerfile.in +++ /dev/null @@ -1,40 +0,0 @@ -# -# Copyright (c) 2018 SUSE -# -# SPDX-License-Identifier: Apache-2.0 - -ARG IMAGE_REGISTRY=docker.io -# NOTE: OS_VERSION is set according to config.sh -FROM ${IMAGE_REGISTRY}/debian:@OS_VERSION@ - -# RUN commands -RUN apt-get update && apt-get --no-install-recommends install -y \ - apt-utils \ - autoconf \ - automake \ - binutils \ - build-essential \ - ca-certificates \ - chrony \ - coreutils \ - curl \ - debianutils \ - debootstrap \ - g++ \ - gcc \ - git \ - libc-dev \ - libstdc++-6-dev \ - m4 \ - make \ - musl \ - musl-dev \ - musl-tools \ - sed \ - systemd \ - tar \ - vim \ - wget - -# This will install the proper packages to build Kata components -@INSTALL_RUST@ diff --git a/tools/osbuilder/rootfs-builder/debian/config.sh b/tools/osbuilder/rootfs-builder/debian/config.sh deleted file mode 100644 index 2419369034..0000000000 --- a/tools/osbuilder/rootfs-builder/debian/config.sh +++ /dev/null @@ -1,20 +0,0 @@ -# -# Copyright (c) 2018 SUSE -# -# SPDX-License-Identifier: Apache-2.0 - -OS_VERSION=${OS_VERSION:-9.5} - -# Set OS_NAME to the desired debian "codename" -OS_NAME=${OS_NAME:-"stretch"} - -PACKAGES="systemd coreutils init chrony kmod" - -# NOTE: Re-using ubuntu rootfs configuration, see 'ubuntu' folder for full content. -source $script_dir/ubuntu/$CONFIG_SH - -# Init process must be one of {systemd,kata-agent} -INIT_PROCESS=systemd -# List of zero or more architectures to exclude from build, -# as reported by `uname -m` -ARCH_EXCLUDE_LIST=() diff --git a/tools/osbuilder/rootfs-builder/debian/rootfs_lib.sh b/tools/osbuilder/rootfs-builder/debian/rootfs_lib.sh deleted file mode 100644 index f6aae26364..0000000000 --- a/tools/osbuilder/rootfs-builder/debian/rootfs_lib.sh +++ /dev/null @@ -1,7 +0,0 @@ -# -# Copyright (c) 2018 SUSE -# -# SPDX-License-Identifier: Apache-2.0 - -# NOTE: Re-using ubuntu rootfs lib, see 'ubuntu' folder for details. -source ${script_dir}/ubuntu/$LIB_SH diff --git a/tools/osbuilder/rootfs-builder/rootfs.sh b/tools/osbuilder/rootfs-builder/rootfs.sh index bfdd4bb271..4f0dd45c59 100755 --- a/tools/osbuilder/rootfs-builder/rootfs.sh +++ b/tools/osbuilder/rootfs-builder/rootfs.sh @@ -193,7 +193,7 @@ docker_extra_args() args+=" -v ${gentoo_local_portage_dir}:/usr/portage/packages" args+=" --volumes-from ${gentoo_portage_container}" ;; - debian | ubuntu | suse) + ubuntu | suse) source /etc/os-release case "$ID" in @@ -519,8 +519,8 @@ EOT chrony_conf_file="${ROOTFS_DIR}/etc/chrony/chrony.conf" chrony_systemd_service="${ROOTFS_DIR}/lib/systemd/system/chronyd.service" ;; - "ubuntu" | "debian") - echo "I am ubuntu or debian" + "ubuntu") + echo "I am ubuntu" chrony_conf_file="${ROOTFS_DIR}/etc/chrony/chrony.conf" chrony_systemd_service="${ROOTFS_DIR}/lib/systemd/system/chrony.service" ;; diff --git a/tools/packaging/static-build/scripts/kata-configure-docker.sh b/tools/packaging/static-build/scripts/kata-configure-docker.sh index 7c53090215..43996b79ed 100644 --- a/tools/packaging/static-build/scripts/kata-configure-docker.sh +++ b/tools/packaging/static-build/scripts/kata-configure-docker.sh @@ -122,7 +122,7 @@ setup() case "$distro" in centos|rhel) $chronic sudo -E yum -y install "$pkg" ;; - debian|ubuntu) $chronic sudo -E apt-get --no-install-recommends install -y "$pkg" ;; + ubuntu) $chronic sudo -E apt-get --no-install-recommends install -y "$pkg" ;; fedora) $chronic sudo -E dnf -y install "$pkg" ;; opensuse|sles) $chronic sudo -E zypper -y install "$pkg" ;; *) die "do not know how to install command $pkg' for distro '$distro'" ;; diff --git a/utils/kata-manager.sh b/utils/kata-manager.sh index 40f647702c..c168e99da2 100755 --- a/utils/kata-manager.sh +++ b/utils/kata-manager.sh @@ -290,7 +290,7 @@ check_deps() case "$ID" in centos|rhel) sudo yum -y install $packages ;; - debian|ubuntu) sudo apt-get -y install $packages ;; + ubuntu) sudo apt-get -y install $packages ;; fedora) sudo dnf -y install $packages ;; opensuse*|sles) sudo zypper install -y $packages ;; *) die "Unsupported distro: $ID"