Deploy the Grails 2.1.1 app for Tomcat as a blown up war?

I am trying to deploy a Grails application in OpenShift, and I am trying to avoid clicking a 50 MB file on the Internet for every change.

I created a project in ~/dev/apps/grails/test to test it

Based on this answer on SO, I added

 grails.war.exploded=true 

to grails-app/conf/BuildConfig.groovy , which caused the creation of this folder:

 /home/sas/.grails/2.1.1/projects/test/stage 

how can i say to create an exploded war in ~/dev/apps/grails/test/target/test-0.1 ?

copy the folder as follows:

 cp -r /home/sas/.grails/2.1.1/projects/test/stage ~/dev/tomcat/webapps/test-0.1 

works fine, but I'm trying to automate the whole process to come up with a quick script run for OpenShift.

+4
source share
1 answer

Just looked at the source code at grails / scripts / _GrailsWarPlugin.groovy

Just needed to add

 grails.project.war.exploded.dir = "target/${appName}-${appVersion}" grails.war.exploded=true 

in grails-app / conf / BuildConfig.groovy

+6
source

All Articles