Search code examples
grailsdeploymenttomcat7maven-tomcat-plugin

Grails deploy: no such warName for class: Tomcat


When I try to deploy to a remote Tomcat server using grails prod deploy tomcat I get the error: enter image description here

Has anybody encountered that?

P.S. On the contrary, the command mvn tomcat7:deploy works.


Solution

  • Problem was resolved by adding def warName = configureWarName() to Tomcat.groovy

    ...
    switch (cmd) {
            case 'deploy':
                war()
                def warName = configureWarName()
                println "Deploying application $serverContextPath to Tomcat"
                deploy(war: warName, url: url, path: serverContextPath, username: user, password: pass)
                break
    ....