We're updating the issue view to help you get more done. 

Add a warning if the a WAR path cannot be set in Tomcat due to a context.xml file

Description

Add a warning so that if the a WAR path cannot be set in Tomcat due to a context.xml file.

See below for explanations.


This does work on a small demo projected created, built, and deployed, however, I have a much larger project that WILL NOT deploys as the name specified. I can't even tell where the name is coming from that is being used. Here are the relevant sections of my build.gradle file that use Cargo:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 import com.bmuschko.gradle.cargo.tasks.remote.CargoRedeployRemote import com.bmuschko.gradle.cargo.convention.Deployable classpath "com.bmuschko:gradle-cargo-plugin:2.2.3" apply plugin: "com.bmuschko.cargo" String warBase = project.hasProperty('warBase') ? project.warBase : 'forecast' String warName = warBase + '.war' println "WAR Name: ${warName}" war { archiveName warName } def cargoVersion = '1.4.5' cargo "org.codehaus.cargo:cargo-core-uberjar:$cargoVersion", "org.codehaus.cargo:cargo-ant:$cargoVersion" cargo { containerId = 'tomcat7x' port = 8080 } task deployApp(type: CargoRedeployRemote) { description = "Deploys forecast-dev.war to Tomcat on port 80" hostname = 'localhost' password = "tomcat" port = 8080 username = "tomcat" deployables = [ new Deployable(file: file("./build/libs/${warName}"), context: "${warBase}") ] }

Status

Assignee

S. Ali Tokmen

Reporter

MichaelA

Components

Fix versions

Priority

Major