X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=ci%2Fenvs%2Fhost-setup0.sh;h=1bd7f1205fd14e34d0cb6968ae04ef8963da3f08;hb=570d93ddbb5e5e54aec9a7c1faf0c24204229c59;hp=28c49b8b88ba1e3f5770cbbaf2b1a2d165985f7b;hpb=76c2ed6659d79ee83c8fc4f00e955268779db826;p=kvmfornfv.git diff --git a/ci/envs/host-setup0.sh b/ci/envs/host-setup0.sh index 28c49b8b8..1bd7f1205 100755 --- a/ci/envs/host-setup0.sh +++ b/ci/envs/host-setup0.sh @@ -9,10 +9,16 @@ ## http://www.apache.org/licenses/LICENSE-2.0 ############################################################################### +source utils.sh source host-config +KERNEL_VERSION=$( getKernelVersion ) +if [ -z $KERNEL_VERSION ];then + echo "Kernel RPM not found" + exit 1 +fi rpmdir=${1:-"/root/workspace/rpm/"} -rpmpat="kernel-4.4*.rpm" +rpmpat="kernel-${KERNEL_VERSION}*.rpm" config_grub () { key=$1 @@ -70,6 +76,6 @@ config_grub 'idle' 'poll' ## Disable clocksource verification at runtime config_grub 'tsc' 'reliable' -grub2-mkconfig -o /boot/grub2/grub.cfg - install_kernel + +grub2-mkconfig -o /boot/grub2/grub.cfg