marko
marko

Reputation: 3776

Grails push to Heroku failed - applicationContext.xml doesn't exist

I try to deploy my Grails 2.1.1 application to Heroku.

I run git push master heroku and it runs for a while (compiles alright, get dependencies, ec), then it gives me this message:

|Building WAR file
   ...........................Error 
   |
   Error executing script War: : Replace: source file /app/.grails/2.1.1/projects/Project/stage/WEB-INF/applicationContext.xml doesn't exist (Use --stacktrace to see the full trace)
 !     Failed to build app
 !     Heroku push rejected, failed to compile Grails app

When I run grails war locally, it works without any issues.

I have done some reading but I haven't found a solid answer. Similar issues that I have read about have been caused by JDK-related issues, or plugins.

Upvotes: 6

Views: 1087

Answers (1)

marko
marko

Reputation: 3776

The solution in this case was to add WEB-INF to my repository. By the default my .gitignore (created via GitHub) ignores WEB-INF.

Upvotes: 10

Related Questions