summaryrefslogtreecommitdiffstats
path: root/bootstrap/vagrant-onap/lib/commons
diff options
context:
space:
mode:
Diffstat (limited to 'bootstrap/vagrant-onap/lib/commons')
-rwxr-xr-xbootstrap/vagrant-onap/lib/commons5
1 files changed, 4 insertions, 1 deletions
diff --git a/bootstrap/vagrant-onap/lib/commons b/bootstrap/vagrant-onap/lib/commons
index 5d0c69108..90f73d230 100755
--- a/bootstrap/vagrant-onap/lib/commons
+++ b/bootstrap/vagrant-onap/lib/commons
@@ -32,13 +32,16 @@ function is_package_installed {
source /etc/os-release || source /usr/lib/os-release
case ${ID,,} in
*suse)
+ CHECK_CMD="zypper search --match-exact --installed"
;;
ubuntu|debian)
- dpkg -s "$@" > /dev/null
+ CHECK_CMD="dpkg -l"
;;
rhel|centos|fedora)
+ CHECK_CMD="rpm -q"
;;
esac
+ ${CHECK_CMD} "$@" &> /dev/null
}
# install_packages() - Install a list of packages