JBoss Community

Slim JBoss

created by Erick Kendall in JBoss Tools - View the full discussion

This is a script I came up with to slim down JBoss 5.1.2 in our environment. Not sure whether I've captured everything but it looks to be a good start at automating.

 

#!/bin/sh

 

JBOSS_HOME=/opt/jboss

 

case "$1" in

        all)

            VAR="all"

            ;;

        default)

            VAR="default"

            ;;

        minimal)

            VAR="minimal"

            ;;

        production)

            VAR="production"

            ;;

        standard)

            VAR="standard"

            ;;

        web)

            VAR="web"

            ;;

        *)

            echo $"Usage: $0 {all|default|minimal|production|standard|web}"

            exit 1

esac

echo $VAR

 

cd $JBOSS_HOME/server/$VAR/deploy

 

# Remove EJB3 Services

 

rm ejb3-connections-jboss-beans.xml

rm ejb3-container-jboss-beans.xml

rm ejb3-interceptors-aop.xml

rm ejb3-timservice-jboss-beans.xml

rm profile-service-secured.jar

 

# Remove EJB2 Services

 

rm ejb2-container-jboss-beans.xml

rm ejb2-timerservice.xml

 

# Remove JUDDI

 

rm juddi-service.sar

 

# Remove Key Generator

 

rm uuid-key-generator.sar

 

# Remove JBoss Messsaging

 

rm -rf messaging

rm jms-ra.rar

 

# Remove JBoss Mail

 

rm mail-service.xml

rm mail-ra.rar

 

# Remove Scheduling

 

rm scheduler-manager-service.xml

rm scheduler-service.xml

rm quartz-ra.rar

 

# Remove Hysersonic DB

 

rm hsqldb-ds.xml

 

# Turn Off Hot Deployment

 

rm hdscanner-jboss-beans.xml

 

cd $JBOSS_HOME/server/$VAR/deployers

 

# Remove Bsh Deplyer

 

rm bsh.deployer

Reply to this message by going to Community

Start a new discussion in JBoss Tools at Community