Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 188139
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T15:57:05+00:00 2026-05-11T15:57:05+00:00

What is the most minimal example of deploying a war to multiple tomcat servers

  • 0

What is the most minimal example of deploying a war to multiple tomcat servers using maven that can be written?

I’ve tried the following URLs and asked the mailing list, but not coming up with anything that was short and would simply work.

  • http://www.nabble.com/Deploying-to-Multiple-Servers-at-Once-td21592419.html

The example should have the servers defined in the example somewhere (with sample usernames/passwords)

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T15:57:06+00:00Added an answer on May 11, 2026 at 3:57 pm

    The idea of Markus Lux can be also applied with a Maven2 solution, with the profiles management:

    <build>     <plugins>         <plugin>             <groupId>org.codehaus.cargo</groupId>             <artifactId>cargo-maven2-plugin</artifactId>         </plugin>     </plugins>     ... </build> <profiles>     <profile>         <id>env-foo1</id>         <!-- Activated when -Denv=foo1 is given as parameter. -->         <activation>             <property>                 <name>env</name>                 <value>foo1</value>             </property>         </activation>         <properties>             <deploy.env>xxx</deploy.env>             <tomcat.manager>http://foo1/manager</tomcat.manager>             <tomcat.manager.username>foo</tomcat.manager.username>             <tomcat.manager.password>bar</tomcat.manager.password>         </properties>     </profile>      <profile>         <id>env-foo2</id>         <!-- Activated when -Denv=foo2 is given as parameter. -->         <activation>             <property>                 <name>env</name>                 <value>foo2</value>             </property>         </activation>         <properties>             <deploy.env>dev</deploy.env>             <tomcat.manager>http://foo2/manager</tomcat.manager>             <tomcat.manager.username>foo</tomcat.manager.username>             <tomcat.manager.password>bar</tomcat.manager.password>         </properties>     </profile>     ...  </profiles>     

    Then, you will just need to run X times the mvn command, with the adequate parameter (-Denv=foo1, -Denv=foo2,…)


    In addition to that, you can enhance this solution by using the Matrix feature of the Hudson Continuous Integration server. I gave a short explanation about this feature here.

    Basically, you just define a ‘normal’ Maven2 job in Hudson, and with the Matrix feature, you can ask Hudson to run this job several times, one per environment. In others words, you create your Hudson job, and then you define the ‘environment axis’ with all possible value for the env parameter:

    • foo1
    • foo2
    • foo3
    • …

    Hudson will then build the application with the mvn command and with the parameter -Denv=foo1.Once this build is finished, it will build the same application but with the parameter -Denv=foo2, and so on…

    This way, Hudson will deploy your application in every environments…

    I hope my solution will help you to reach your goals…

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Most things are dynamic in SSRS i.e you can create a custom expression for
Most objects in SAP ERP can be double clicked to get more information in
We're building a site that will have very minimal code, it's mostly just going
What is the most minimal way to dynamically interchange UIElement s at a certain
Here is an minimal example of the error I get. If I understood the
I have a long-lived server application that is designed to run with minimal downtime
When using malloc and doing similar memory manipulation can I rely on sizeof( char
Let us take this example scenario: There exists a really complex function that involves
If my requirements dictate that most of my accesses to the list are for
Starting with urllib2 and feedparser libraries in Python I'm getting the following error most

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.