Skip to content

Commit ecf00a0

Browse files
Merge pull request #4182 from pmtk/remove-rhui-client
USHIFT-4889: Remove AWS RHUI client as it re-enables RHUI repos
2 parents bf738fb + 3c0bb84 commit ecf00a0

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

scripts/devenv-builder/configure-vm.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,12 +129,19 @@ if ${RHEL_SUBSCRIPTION}; then
129129
--enable "rhel-${OSVERSION}-for-$(uname -m)-baseos-rpms" \
130130
--enable "rhel-${OSVERSION}-for-$(uname -m)-appstream-rpms"
131131

132+
# Disable the AWS' Red Hat Update Infrastructure (RHUI) repositories.
133+
# Having enabled both RHUI and repos from SubMgr might cause conflicts.
132134
if dnf repolist --enabled | grep -q "^rhel-${OSVERSION}-baseos-rhui-rpms"; then
133135
sudo dnf config-manager --set-disabled "rhel-${OSVERSION}-baseos-rhui-rpms"
134136
fi
135137
if dnf repolist --enabled | grep -q "^rhel-${OSVERSION}-appstream-rhui-rpms"; then
136138
sudo dnf config-manager --set-disabled "rhel-${OSVERSION}-appstream-rhui-rpms"
137139
fi
140+
141+
# Remove the rh-amazon-rhui-client as its upgrade process re-enables the RHUI repos.
142+
if sudo rpm -qa | grep -v rh-amazon-rhui-client; then
143+
sudo dnf remove -y rh-amazon-rhui-client
144+
fi
138145
fi
139146
fi
140147

0 commit comments

Comments
 (0)