Skip to content

Commit 44a6ba6

Browse files
cfergeaupraveenkumar
authored andcommitted
microshift: Drop RH internal 'brew' requirement
microshift is officially released in RH repos, and microshift.sh already requires a subscription, so we can use `yum download` instead of `brew download-build`. I've checked that setting `MICROSHIFT_NVR` works for 4.13 releases.
1 parent fe4f380 commit 44a6ba6

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

microshift.sh

+5-7
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,6 @@ INSTALL_DIR=crc-tmp-install-data
1313
SNC_PRODUCT_NAME=${SNC_PRODUCT_NAME:-crc}
1414
BASE_DOMAIN=${CRC_BASE_DOMAIN:-testing}
1515
MIRROR=${MIRROR:-https://mirror.openshift.com/pub/openshift-v4/$ARCH/clients/ocp}
16-
MICROSHIFT_NVR=${MICROSHIFT_NVR:-}
17-
18-
if [ ! -n "${MICROSHIFT_NVR}" ]; then
19-
echo "Please specify MICROSHIFT_NVR, which you can get from internal brew (ex. microshift-4.12.5-202302222013.p0.g0165ac4.assembly.4.12.5.el8 )"
20-
exit 1
21-
fi
2216

2317
if ! grep -q -i "release 9" /etc/redhat-release
2418
then
@@ -73,7 +67,11 @@ function enable_repos {
7367
function download_microshift_rpm {
7468
local pkgDir=$1
7569
pushd ${pkgDir}
76-
brew download-build --quiet --arch noarch --arch ${ARCH} ${MICROSHIFT_NVR}
70+
if [ -n "${MICROSHIFT_NVR-}" ]; then
71+
sudo yum download --downloadonly microshift-${MICROSHIFT_NVR-} microshift-networking-${MICROSHIFT_NVR-} microshift-release-info-${MICROSHIFT_NVR-} microshift-selinux-${MICROSHIFT_NVR-} microshift-greenboot-${MICROSHIFT_NVR-}
72+
else
73+
sudo yum download --downloadonly microshift microshift-networking microshift-release-info microshift-selinux microshift-greenboot
74+
fi
7775
popd
7876
}
7977

0 commit comments

Comments
 (0)