Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removing EPEL, which is no longer needed. #1884

Merged
merged 3 commits into from
Dec 6, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 4 additions & 35 deletions bootstrap-salt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2099,20 +2099,13 @@ __rpm_import_gpg() {
#----------------------------------------------------------------------------------------------------------------------
__yum_install_noinput() {

ENABLE_EPEL_CMD=""
# Skip Amazon Linux for the first round, since EPEL is no longer required.
# See issue #724
if [ $_DISABLE_REPOS -eq $BS_FALSE ] && [ "$DISTRO_NAME_L" != "amazon_linux_ami" ]; then
ENABLE_EPEL_CMD="--enablerepo=${_EPEL_REPO}"
fi

if [ "$DISTRO_NAME_L" = "oracle_linux" ]; then
# We need to install one package at a time because --enablerepo=X disables ALL OTHER REPOS!!!!
for package in "${@}"; do
yum -y install "${package}" || yum -y install "${package}" ${ENABLE_EPEL_CMD} || return $?
yum -y install "${package}" || yum -y install "${package}" || return $?
done
else
yum -y install "${@}" ${ENABLE_EPEL_CMD} || return $?
yum -y install "${@}" || return $?
fi
} # ---------- end of function __yum_install_noinput ----------

Expand Down Expand Up @@ -4374,30 +4367,6 @@ install_fedora_check_services() {
#
# CentOS Install Functions
#
__install_epel_repository() {
if [ ${_EPEL_REPOS_INSTALLED} -eq $BS_TRUE ]; then
return 0
fi

# Check if epel repo is already enabled and flag it accordingly
if yum repolist | grep -q "^[!]\\?${_EPEL_REPO}/"; then
_EPEL_REPOS_INSTALLED=$BS_TRUE
return 0
fi

# Download latest 'epel-next-release' package for the distro version directly
epel_next_repo_url="${HTTP_VAL}://dl.fedoraproject.org/pub/epel/epel-next-release-latest-${DISTRO_MAJOR_VERSION}.noarch.rpm"

# Download latest 'epel-release' package for the distro version directly
epel_repo_url="${HTTP_VAL}://dl.fedoraproject.org/pub/epel/epel-release-latest-${DISTRO_MAJOR_VERSION}.noarch.rpm"

yum -y install "${epel_next_repo_url}" "${epel_repo_url}"

_EPEL_REPOS_INSTALLED=$BS_TRUE

return 0
}

__install_saltstack_rhel_repository() {
if [ "$ITYPE" = "stable" ]; then
repo_rev="$STABLE_REV"
Expand Down Expand Up @@ -4520,7 +4489,6 @@ install_centos_stable_deps() {
fi

if [ "$_DISABLE_REPOS" -eq "$BS_FALSE" ]; then
__install_epel_repository || return 1
__install_saltstack_rhel_repository || return 1
fi

Expand Down Expand Up @@ -4562,6 +4530,8 @@ install_centos_stable_deps() {
fi
fi

__PACKAGES="${__PACKAGES} procps"

# shellcheck disable=SC2086
__yum_install_noinput ${__PACKAGES} || return 1

Expand Down Expand Up @@ -4824,7 +4794,6 @@ install_centos_onedir_deps() {
fi

if [ "$_DISABLE_REPOS" -eq "$BS_FALSE" ]; then
__install_epel_repository || return 1
__install_saltstack_rhel_onedir_repository || return 1
fi

Expand Down