Search code examples
tomcatdeploymentcargo

Deploy on a remote server war + conf (cargo?)


I'm searching for something that can deploy on an application server (tomcat) a war and its relative context.xml file and/or a properties file for the application. The problem is that the properties file should be in classpath of the application context (in conf/Catalina/localhost).

To make this i've found the Cargo Maven Plugin that seems what I need, but how can I make the deployment of the conf files in a remote server? I'm not sure that this is possible...

otherwise you know someother way to do this?

write in short i need somenthing to make mvn goal:install -P production and the project is installed in a remote server without do nothing.


Solution

  • It's possible. You just have to bundle both files in your WAR file. The context.xml sits in META-INF/context.xml and the properties file under WEB-INF/classes.