Netbeans: Deploying Java Applications for Remote Tomcat

Is there an easy way to automatically deploy a web service / Java web application etc. on a tomcat remote server? I currently have to manually copy the .war file.

+5
source share
1 answer

Personally, I add the β€œdeploy” target in the build.xml file that contains the <scp> to transfer the war file.

UPDATE:

Here is an example:

<target name="deploy" depends="dist">
    <scp todir="${user.name}@www.myserver.com:tomcat-base/webapps/"
            keyfile="${user.home}/.ssh/myserver.key"
            passphrase="BlaBlaBla" trust="true">
        <fileset dir="dist" includes="myapp.war"/>
    </scp>
</target>
+6
source

All Articles