Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Property name

Java constant (for the Java API)

Description

Valid values

Default value

Example

cargo.hostname
GeneralPropertySet.HOSTNAME

Host name on which the container listens to

string"

localhost
"
"
myserver
"
cargo.jvmargs
GeneralPropertySet.JVMARGS

JVM args to be used when starting/stopping containers

string

N/A
"
-Xmx500m
"
cargo.logging
GeneralPropertySet.LOGGING

Level representing the quantity of information we wish to log

"low", " medium" or " or high""

medium
"
"
high
"
cargo.protocol
GeneralPropertySet.PROTOCOL

Protocol on which the container is listening to

"http", " or https""

http
"
"
http
"
cargo.remote.password
RemotePropertySet.PASSWORD

Password to use to authenticate against a remote container (when deploying for example)

string

Depends on the container"

manager
"
cargo.remote.username
RemotePropertySet.USERNAME

Username to use to authenticate against a remote container (when deploying for example)

string

Depends on the container"

system
"
cargo.rmi.port
GeneralPropertySet.RMI_PORT

The port to use when communicating with this server, for example to start and stop it

integer

Depends on the container"

1099
"
cargo.servlet.port
ServletPropertySet.PORT

Port on which the Servlet/JSP container listens to

integer"

8080
"
"
8280
"
cargo.servlet.users
ServletPropertySet.USERS

Allow defining users and map to roles

string

N/A"

name1:pwd1:role11,...,role1N|name2:pwd2:role21,...,role2N|...
"
Info
titleDatasource and Resource configuration

In addition to the "simple" properties presented here, some container also support properties for setting up datasources. You can read more on: DataSource and Resource Support.

...

Code Block
xml
xml
<build>
  <plugins>
    <plugin>
      <groupId>org.codehaus.cargo.maven2</groupId>
      <artifactId>cargo-maven2-plugin</artifactId>
      <configuration>
        <container>
          <containerId>tomcat5x</containerId>
          [...]
        </container>
        <configuration>
          <properties>
            <cargo.servlet.port>8081</cargo.servlet.port>
          </properties>
        </configuration>
        [...]
      </configuration>
    </plugin>
  </plugins>
</build>

Using Java properties

Starting from CARGO 1.1.2, all All configuration properties (be it with the Java API, ANT tasks or Maven2/Maven3 goals) can also be overriden using Java properties.

For example, with Maven:

Code Block
mvn -Dcargo.servlet.port=8082 cargo:start