You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

35 lines
684 B

#!/bin/sh
set -e
default=/etc/default/ngcp-rtpengine-daemon
name=ngcp-rtpengine
if [ -x /usr/sbin/ngcp-virt-identify ]; then
if /usr/sbin/ngcp-virt-identify --type container; then
VIRT="yes"
fi
fi
if [ "$VIRT" = "yes" ]; then
echo "Container environment detected. Skip dkms check"
else
fallback=$(awk '/^NO_FALLBACK=(1|yes)/ { print "yes" }' "$default")
if [ -x /usr/sbin/dkms ]; then
isadded=`dkms status -m "$name"`
else
isadded="no"
fi
if [ "${fallback}" = "yes" ] && [ "x${isadded}" = "x" ] ; then
echo "dkms module not found and NO_FALLBACK set to 'yes'"
echo "Don't restart yet, ngcp-rtpengine-kernel-dkms will try"
exit 0
fi
fi
#DEBHELPER#
exit 0