#! /bin/sh
JBOSS_SERVER=$JBOSS_HOME/server/otcm-server
JBOSS_DEPLOY=$JBOSS_SERVER/deploy
JBOSS_LIB=$JBOSS_SERVER/lib
JBOSS_CONF=$JBOSS_SERVER/conf
JBOSS_WEB=$JBOSS_DEPLOY/ROOT.war
mkdir $1
cp $1.tar $1
cd $1
tar -xvf $1.tar
rm $1.tar
cd ..
cp $1/*.xml $JBOSS_DEPLOY
cp $1/*.ear $JBOSS_DEPLOY
cp $1/*.sar $JBOSS_DEPLOY
cp $1/*.jar $JBOSS_LIB
cp $1/lib/* $JBOSS_LIB
cp $1/conf/* $JBOSS_CONF
rm -rf $JBOSS_SERVER/tmp
rm -rf $JBOSS_SERVER/work
as you can see from the script i need to move the tar to another folder then unzip the content, after that i copy the contents from that tar to their respective folders.
the main part i cant get working is the unzipping part…
Take a look at the ss64 website bash section. Find your commands, and look up the equivalent windows command. Note that windows does not have tar and you will need to install it, or an alternative.