This is an automated email from the ASF dual-hosted git repository.
sekikn pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/bigtop.git
The following commit(s) were added to refs/heads/master by this push:
new 5b0dd2e BIGTOP-3331: Provisioner Deployment failed on Fedora (#619)
5b0dd2e is described below
commit 5b0dd2e62886a3ed4d8d42183e186e541c5e9744
Author: Yuqi <[email protected]>
AuthorDate: Thu Apr 2 20:22:37 2020 +0800
BIGTOP-3331: Provisioner Deployment failed on Fedora (#619)
'yum.conf' doesn't exist in Fedora-29/31 environment.
It causes format error when echo "gpgcheck=0" >> /etc/yum.conf
So the provisioner deployment failed in Fedora-29/31.
Change-Id: I798769bbb38cb2eb6fa9d178c2569cb63c22876c
Signed-off-by: Yuqi Gu <[email protected]>
---
provisioner/utils/setup-env-centos.sh | 15 +++++++++++++--
1 file changed, 13 insertions(+), 2 deletions(-)
diff --git a/provisioner/utils/setup-env-centos.sh
b/provisioner/utils/setup-env-centos.sh
index 2e4916c..55dcdad 100755
--- a/provisioner/utils/setup-env-centos.sh
+++ b/provisioner/utils/setup-env-centos.sh
@@ -36,11 +36,22 @@ fi
if [ $enable_local_repo == "true" ]; then
echo "Enabling local yum."
yum -y install yum-utils
- sudo echo "gpgcheck=0" >> /etc/yum.conf
+
+ if [ -f /etc/os-release ]; then
+ . /etc/os-release
+ fi
+ case ${ID} in
+ fedora)
+ sed -i 's/gpgcheck=1/gpgcheck=0/g' /etc/dnf/dnf.conf
+ ;;
+ centos)
+ sudo echo "gpgcheck=0" >> /etc/yum.conf
+ ;;
+ esac
+
sudo yum-config-manager --add-repo file:///bigtop-home/output
sudo echo "gpgcheck=0" >> /etc/yum.repos.d/bigtop-home_output.repo
sudo echo "priority=10" >> /etc/yum.repos.d/bigtop-home_output.repo
else
echo "local yum = $enable_local_repo ; NOT Enabling local yum. Packages
will be pulled from remote..."
fi
-