Ask Your Question
3

How to deploy WAR files to Tomcat/Apache using Puppet?

asked 2013-11-15 21:03:04 -0500

altitude gravatar image

Hi, I'm new to Jenkins/Maven CI, although have used Cruise Control years ago as an end user. Just come across Puppet. The Jenkins projects have built some WAR files which I need to automatically deploy to Tomcat, then later Apache httpd too. These run on other VMs. How do I do deploy them please? Others are suggesting writing shell scripts. But I am thinking further ahead too. Is there an example Puppet Module that demonstrates this, and which I can reuse please? Need to be quick and easy. Haven't had time to read the online help and ... (more)

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2013-11-16 16:32:29 -0500

spuder gravatar image

updated 2013-11-16 16:37:07 -0500

Consider the following tutorial

http://www.tomcatexpert.com/blog/2010/04/29/deploying-tomcat-applications-puppet

Basically, do something like this

define tomcat::deployment($path) {

include tomcat
notice("Establishing    http://$hostname:${tomcat::tomcat_port}/$name/")


  file { "/var/lib/tomcat6/webapps/${name}.war":
    owner => 'root',
    source => $path,
  }

}
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2013-11-15 21:03:04 -0500

Seen: 4,268 times

Last updated: Nov 16 '13