6 # -o pipefail: Fail on errors in scripts this calls, give stacktrace
9 if [ -f /usr/bin/yum ]; then
11 sudo yum remove -y opendaylight
13 # Verify ODL not installed
14 if yum list installed opendaylight; then
15 # Fail if exit code 0, ie ODL is still installed
16 echo "OpenDaylight unexpectedly still installed"
19 echo "OpenDaylight not installed, as expected"
21 elif [ -f /usr/bin/zypper ]; then
23 sudo zypper -n remove opendaylight
25 # Verify ODL not installed
26 if zypper search --installed-only opendaylight; then
27 # Fail if exit code 0, ie ODL is still installed
28 echo "OpenDaylight unexpectedly still installed"
31 echo "OpenDaylight not installed, as expected"
34 echo "The package manager is not supported (not yum or zypper)"