chore: remove check for already installed packages before removing (#2763)
* chore: remove check for already installed packages before removing There is very little point to doing this, if the package isn't installed that we are trying to remove, then it should simply fail. * chore: also remove removal check for dx We don't currently (and probably also won't in the future) remove things from the base. DX should be an addition.
This commit is contained in:
parent
2c1a15e216
commit
caaf781326
2 changed files with 1 additions and 22 deletions
|
|
@ -184,15 +184,7 @@ EXCLUDED_PACKAGES=(
|
|||
podman-docker
|
||||
)
|
||||
|
||||
# Remove excluded packages if they are installed
|
||||
if [[ "${#EXCLUDED_PACKAGES[@]}" -gt 0 ]]; then
|
||||
readarray -t INSTALLED_EXCLUDED < <(rpm -qa --queryformat='%{NAME}\n' "${EXCLUDED_PACKAGES[@]}" 2>/dev/null || true)
|
||||
if [[ "${#INSTALLED_EXCLUDED[@]}" -gt 0 ]]; then
|
||||
dnf5 -y remove "${INSTALLED_EXCLUDED[@]}"
|
||||
else
|
||||
echo "No excluded packages found to remove."
|
||||
fi
|
||||
fi
|
||||
dnf -y remove "${EXCLUDED_PACKAGES[@]}"
|
||||
|
||||
## Pins and Overrides
|
||||
## Use this section to pin packages in order to avoid regressions
|
||||
|
|
|
|||
|
|
@ -105,19 +105,6 @@ echo "Installing DX COPR packages with isolated repo enablement..."
|
|||
copr_install_isolated "karmab/kcli" "kcli"
|
||||
copr_install_isolated "ublue-os/packages" "ublue-os-libvirt-workarounds"
|
||||
|
||||
# DX packages to exclude - common to all versions
|
||||
EXCLUDED_PACKAGES=()
|
||||
|
||||
# Remove excluded packages if they are installed
|
||||
if [[ "${#EXCLUDED_PACKAGES[@]}" -gt 0 ]]; then
|
||||
readarray -t INSTALLED_EXCLUDED < <(rpm -qa --queryformat='%{NAME}\n' "${EXCLUDED_PACKAGES[@]}" 2>/dev/null || true)
|
||||
if [[ "${#INSTALLED_EXCLUDED[@]}" -gt 0 ]]; then
|
||||
dnf5 -y remove "${INSTALLED_EXCLUDED[@]}"
|
||||
else
|
||||
echo "No excluded packages found to remove."
|
||||
fi
|
||||
fi
|
||||
|
||||
rsync -rvK /ctx/system_files/dx/ /
|
||||
|
||||
# Load iptable_nat module for docker-in-docker.
|
||||
|
|
|
|||
Loading…
Reference in a new issue