Skip to content

Commit

Permalink
add 'containerd' package to pre-install package deps for Ubuntu 24.04…
Browse files Browse the repository at this point in the history
… and Amazon Linux 2023 (#5387)
  • Loading branch information
laverya authored Sep 4, 2024
1 parent 24e0e34 commit 151d59d
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 3 deletions.
20 changes: 17 additions & 3 deletions addons/containerd/template/script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,17 @@ dockerout $os addons/containerd/template/$dockerfile $version
EOT
}

function add_os_package_to_manifest_file() {
local version=$1
local ospackage=$2
local package=$3
local file=/tmp/containerd/$version/Manifest

cat <<EOT >> $file
$ospackage $package
EOT
}

function add_override_os_to_manifest_file() {
local version=$1
local override_version=$2
Expand Down Expand Up @@ -271,10 +282,13 @@ function find_common_versions() {
add_supported_os_to_manifest_file "$version" "ubuntu-22.04" "Dockerfile.ubuntu22"
fi

# for amazon 2023 we use the containerd version provided by the
# operating system. on this case we just set all found versions as
# supported.
# for amazon 2023 and Ubuntu 24.04 we use the containerd version provided by the
# operating system. on this case we just set all found versions as supported.
add_supported_os_to_preflight_file "$version" "amazon" ">=" "2023"
add_supported_os_to_manifest_file "$version" "ubuntu" "=" "24.04"
add_os_package_to_manifest_file "$version" "yum2023" "containerd"
add_os_package_to_manifest_file "$version" "yum2023" "libzstd"
add_os_package_to_manifest_file "$version" "apt24" "containerd"

VERSIONS+=("$version")
done
Expand Down
6 changes: 6 additions & 0 deletions bin/save-manifest-assets.sh
Original file line number Diff line number Diff line change
Expand Up @@ -477,6 +477,12 @@ while read -r line || [ -n "$line" ]; do
sudo chown -R $UID "$OUT_DIR"/ubuntu-16.04
;;

apt24)
mkdir -p "$OUT_DIR"/ubuntu-24.04
package=$(echo "$line" | awk '{ print $2 }')
echo "$package" >> "$OUT_DIR"/ubuntu-24.04/Deps
;;

yum)
package=$(echo "$line" | awk '{ print $2 }')
pkgs_rhel7+=("$package")
Expand Down

0 comments on commit 151d59d

Please sign in to comment.