#!/bin/sh

if [ "$appHome" = "" ]; then
  appHome="/opt/webservice"
fi
if [ "$varPath" = "" ]; then
  varPath="/var/opt/webservice"
fi

PLT_QUERY_FILE=/usr/sbin/system-is-server

if [ -f ${PLT_QUERY_FILE} ]; then

  # it seems os4k-platform-support is installed, so we have a platform version > 7.1.x
  ${PLT_QUERY_FILE}
  rc=$?
  if [ "$rc" = "0" ]; then
    echo "Hardware is a COTS (Standard Server)"
    exit 1
  else
    echo "Hardware is not a COTS (Standard Server)"    
    exit 0
  fi
else
  # it seems os4k-platform-support is not installed, so we have a platform version <=  7.1.7
  # in this case we assume its not an COTS
    echo "Hardware can not be determined"
    exit 0
fi  