#!/bin/bash

#usage
function usage()
{
    echo "USAGE: pva-pp-preUpgrade" 1>&2
}

###################### Include common files #######################

. ${0/%pva-pp-*/pva-pp-functions.sh} || { echo "Failed to load hint functions"; exit -1;}

############################### Go  ##############################

echo "------------------------------------------------------------------------------------------------"
date "+%b %e %T PVA Power Panel preupgrade configuration : start"

# parse options
eval set -- $* --
while true ; do
    case "$1" in
        --help)		usage; exit 0 ;;
        --)		shift ; break ;;
        *) 		shift ;;
    esac
done

# if PP is installed on slave we should call pva-cp-preInstall
preupgrade || abort $? "PVA Power Panel preupgrad3e configuration failed"

date "+%b %e %T PVA Power Panel preupgrade configuration : stop"
echo "------------------------------------------------------------------------------------------------"

exit 0


