From: Zack Cerza Date: Fri, 1 Feb 2019 00:36:17 +0000 (+0000) Subject: install-deps.sh: Fixes for RHEL 7 X-Git-Tag: v14.1.0~127^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F26393%2Fhead;p=ceph.git install-deps.sh: Fixes for RHEL 7 Signed-off-by: Zack Cerza --- diff --git a/install-deps.sh b/install-deps.sh index e1f7b1360fc..085e2c9c6a2 100755 --- a/install-deps.sh +++ b/install-deps.sh @@ -299,15 +299,16 @@ else fi ;; centos|rhel|ol|virtuozzo) + MAJOR_VERSION="$(echo $VERSION_ID | cut -d. -f1)" $SUDO yum install -y yum-utils if test $ID = rhel ; then - $SUDO yum-config-manager --enable rhel-$VERSION_ID-server-optional-rpms + $SUDO yum-config-manager --enable rhel-$MAJOR_VERSION-server-optional-rpms fi - $SUDO yum-config-manager --add-repo https://dl.fedoraproject.org/pub/epel/$VERSION_ID/x86_64/ + $SUDO yum-config-manager --add-repo https://dl.fedoraproject.org/pub/epel/$MAJOR_VERSION/x86_64/ $SUDO yum install --nogpgcheck -y epel-release - $SUDO rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-$VERSION_ID + $SUDO rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-$MAJOR_VERSION $SUDO rm -f /etc/yum.repos.d/dl.fedoraproject.org* - if test $ID = centos -a $VERSION_ID = 7 ; then + if test $ID = centos -a $MAJOR_VERSION = 7 ; then case $(uname -m) in x86_64) $SUDO yum -y install centos-release-scl