Posts

Showing posts from September, 2019

Deploy war application to multiple tomcat servers using ANT Script

It is tedious work if you have say 5 servers and you need to deploy same application in all servers manually. So, I developed below ant script which will deploy the application in all servers with single command. All you need to do is to update server details in the build.properties file. build.xml <?xml version="1.0" encoding="UTF-8"?> <project name="OneClickDeploy" default="deploy" basedir="."> <property file="build.properties" /> <property name="war-file-name" value="${project-name}.war" /> <property name="build-directory" value="${build-directory}" /> <taskdef name="deploy" classname="org.apache.catalina.ant.DeployTask" /> <taskdef name="undeploy" classname="org.apache.catalina.ant.UndeployTask" /> <taskdef name="reload" classname="org.apache.cata...