Trinidad allows you to run a rails or rackup applications within an embedded Apache Tomcat container.
This project was initially called “Tomcat-rails” but due to legal issues with the ASF and the Tomcat trademark it has been renamed.
jgem install trinidad jgem install calavera-trinidad -s http://gems.github.com
cd myrailsapp jruby -S trinidad
Trinidad allows you to configure some parameters when the server is started from the command line, the following is a list of the currently supported options:
* -p, --port PORT => port to bind to. * -e, --env ENVIRONMENT => rails environment. * -c, --context CONTEXT => application context path. * --lib, --jars LIBS_DIR => directory containing jars. * --classes CLASSES_DIR => directory containing classes. * --rackup [RACKUP_FILE] => run a provided rackup file instead of a rails application, by default it's config.ru. * --public PUBLIC_DIR => specify the public directory for your application, by default it's 'public'.
The server can also be configured from a yaml file. If a file is not especified, the server tries to load the file config/tomcat.yml. Within this file you can add other options like jruby.min.runtimes(:jruby_min_runtimes) or jruby.max.runtimes(:jruby_max_runtimes).
jruby -S trinidad -f jruby -S trinidad --config my_custom_configuration.yml
You can also specify a default web.xml to config your web application. By default the server tries to load the file config/web.xml but you can modify this path adding the option default_web_xml within your configuration file.
Other advanced options can be found in the wiki: wiki.github.com/calavera/trinidad/advanced-configuration
Copyright © 2009 David Calavera<email@example.com>. See LICENSE for details.