From e0d0bfb46f3f34ea8b7c83943bbea382518446eb Mon Sep 17 00:00:00 2001 From: qoijjj <129108030+qoijjj@users.noreply.github.com> Date: Thu, 10 Oct 2024 14:56:54 -0700 Subject: [PATCH] fix: ensure zstd is included in the image as it's required for the install script --- modules/brew/brew.sh | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/modules/brew/brew.sh b/modules/brew/brew.sh index fdc96aec..b6bd8cae 100644 --- a/modules/brew/brew.sh +++ b/modules/brew/brew.sh @@ -22,6 +22,19 @@ if ! command -v gcc &> /dev/null; then fi fi +# Check if zstd is installed & install it if it's not +if ! command -v zstd &> /dev/null; then + if command -v rpm-ostree &> /dev/null; then + echo "Installing \"zstd\" package, which is necessary for Brew to function" + rpm-ostree install zstd + else + echo "ERROR: \"zstd\" package could not be found" + echo " Brew's installer depends on \"zstd\" in order to function" + echo " Please include \"zstd\" in the list of packages to install with the system package manager" + exit 1 + fi +fi + # Module-specific directories and paths MODULE_DIRECTORY="${MODULE_DIRECTORY:-/tmp/modules}"