Chef cookbook for Apache Tomcat in clustered environment
Linux Debian (currently tested on squeeze)
node.default - path to install tomcat node.default - full tomcat path after installation node.default - by default 8005 node.default - by default 8080 node.default - by default 8009 node.default - use the host address node.default - by default “228.0.0.4” node.default - by default 45564 node.default - use the host address node.default - by default 4000 node.default - temp dir for deploying node.default - dir to deploy WARs node.default - dir to watch WARs
Recipe could be checked using chef-solo utility. All the attributes could be passed via son string.
Create node.json file. Example:
{
"installPath":"/home/paas", "tomcatPath":"/home/paas/apache-tomcat-7.0.11", "serverPort":8005, "connectorPort":8080, "ajpPort":8009, "hostIP":"192.168.240.126", "multicastIP":"228.0.0.4", "multicastPort":45564, "nioAddress":"192.168.240.126", "nioPort":4000, "tempDir":"/home/paas/apache-tomcat-7.0.11/webapps/", "deployDir":"/home/paas/apache-tomcat-7.0.11/webapps/", "watchDir":"/tmp/war-listen/", "run_list": [ "recipe[apache-tomcat::default]" ]
}
Run chef-solo utility:
chef-solo -c ~/solo.rb -j ~/node.json
For more information see opscode tutorials.