CubaWarDistribution Error

Hi, I am unable to create war file using CubaWarDistribution
find the below code


task createWarDistr(dependsOn: [coreModule.buildWar, webModule.buildWar], type: CubaWarDistribution) {
appHome = ‘${app.home}’
singleWar = false
}

getting the following error

Caused by: groovy.lang.MissingPropertyException: Could not get unknown property ‘CubaWarDistribution’ for root project ‘keansa_cloud’ of type org.gradle.api.Project.
at org.gradle.internal.metaobject.AbstractDynamicObject.getMissingProperty(AbstractDynamicObject.java:85)
at org.gradle.internal.metaobject.AbstractDynamicObject.getProperty(AbstractDynamicObject.java:62)
at org.gradle.groovy.scripts.BasicScript.propertyMissing(BasicScript.java:70)
at org.gradle.groovy.scripts.Script.getProperty(Script.java:56)
at build_78exc5cvtrzel4hghbum7mrhz.run(E:\CubaExamples\keansa_cloud\build.gradle:270)
at org.gradle.groovy.scripts.internal.DefaultScriptRunnerFactory$ScriptRunnerImpl.run(DefaultScriptRunnerFactory.java:90)
… 58 more

Thanks Olga,

War created successfully but the issue with war is , it is working in tomcat but not in glassfish.
Can you give a hint here

Could you share the details of the issue: your Glassfish version and log files.

Hi Mallik,

There is no CubaWarDistribution task type in the platform. Try to use the buildWar task of CubaWarBuilding type.