chravis
chravis

Reputation: 103

Grails 4 WAR file confusion

I have a Grails application that I have upgraded from 3.3.0 to 4.0.3. In my build.gradle file I have the following

war {
    archiveName 'Wolf.war'
}

In version 3, this would name my war file Wolf.war when running "grails war" just as expected. However, in Grails 4 this no longer works for me. I know this is related to Gradle. I have Gradle 5.1.1, and per the docs the archiveName property is deprecated (but should still work?).

My question is, what is the proper way, in a Grails 4 app using Gradle 5 (or above?) to force the name of the war file being produced by the "grails war" command?

Upvotes: 2

Views: 698

Answers (1)

Jeff Scott Brown
Jeff Scott Brown

Reputation: 27220

Assuming you are using the default build config, you should use bootWar instead of war.

bootWar {
    archiveName 'Wolf.war'
}

Upvotes: 5

Related Questions