From f845220cd17f89c8e1c68aecb3f0c7e82a56aa03 Mon Sep 17 00:00:00 2001 From: sharath reddy Date: Wed, 25 May 2022 16:07:43 +0530 Subject: [PATCH] add sudo Issue-ID: KUB-64 Signed-off-by: sharath reddy Change-Id: If7b5b20a46881fb06e873f3fd8d4427dad7bdb91 Signed-off-by: sharath reddy Reviewed-on: https://gerrit.opnfv.org/gerrit/c/kuberef/+/73388 Tested-by: jenkins-ci Reviewed-by: Dan Xu Reviewed-by: Michael Pedersen Reviewed-by: Georg Kunz Reviewed-by: Kanagaraj Manickam --- functions.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/functions.sh b/functions.sh index 63f1490..4eaa281 100755 --- a/functions.sh +++ b/functions.sh @@ -69,7 +69,7 @@ check_prerequisites() { #------------------------------------------------------------------------------- if [ "$OS_ID" == "ubuntu" ]; then - apt update + sudo apt update -y ansible --version RESULT=$? if [ $RESULT -ne 0 ]; then @@ -109,7 +109,7 @@ check_prerequisites() { elif [ "$OS_ID" == "centos" ]; then - yum update + sudo yum update -y ansible --version RESULT=$? if [ $RESULT -ne 0 ]; then -- 2.16.6