Versions Compared

Key

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

At the completion of this section, you will:

...

Configure the Maven runMaven operation by adding it to the center pane and the plugin will open for additional configuration.

  1. The runMaven operation requires one or more Run Phases to be specified. Since we want to compile and generate a WAR, we will use the default package phase.

...

  1. The Arguments input is where we can specify any extra arguments we want passed to the mvn command. Our endpoint is running Java 7 so we now need to tell Java to use TLS version 1.2, or we won't be allowed to access the Maven Central Repository. To do this we have to add -Dhttps.protocols=TLSv1.2 to the Arguments.
  2. The plugin allows us to save artifacts directly to the Artifacts Repository by checking the Save Artifacts option. Checking this will cause the plugin to save all files in the Artifacts Subfolder into the Artifact Repository.
  3. The Artifacts Subfolder is the folder where Maven will put the packaged WAR, so we're keeping the default value of target.

The runMaven operation knows where the project was cloned, so the developer doesn't have to worry about the details. At the successful completion of the runMaven operation, a WAR file will be generated as an artifact and will automatically be pulled back to the artifact repository.  Select OK.

...

Add the deploy operation of the Tomcat plugin by adding it to the center pane and the plugin will open for additional configuration. This operation requires no configuration on the workflow operation, it will get all of the necessary information from either the Environment Instance (configured later in this tutorial), or by looking it up on the Tomcat server. The operation will automatically have access to the artifact created by the build workflow.

...