问题
I'm trying to deploy my grails app to Cloud Foundry and I'm getting the eror below.
I'm wondering if my mysql datasource is correctly configured in DataSource.groovy and this could be causing the issue or I'm missing something else.
====> /logs/staging.log <====
Uploading Application:
Checking for available resources: OK
Processing resources: OK
Packing application: OK
Uploading (116K): OK
Push Status: OK
Staging Application: ..Error 310: Staging failed: 'Staging plugin failed staging application:
/var/vcap/packages/stager/stager/vendor/bundle/ruby/1.9.1/gems/vcap_staging-0.1.44/lib/vcap/staging/plugin/java_web/plugin.rb:25:in block in stage_application': Web application staging failed: web.xml not found (RuntimeError)
from /var/vcap/packages/stager/stager/vendor/bundle/ruby/1.9.1/gems/vcap_staging-0.1.44/lib/vcap/staging/plugin/java_web/plugin.rb:19:in
chdir'
from /var/vcap/packages/stager/stager/vendor/bundle/ruby/1.9.1/gems/vcap_staging-0.1.44/lib/vcap/staging/plugin/java_web/plugin.rb:19:in stage_application'
from /var/vcap/packages/stager/stager/bin/run_plugin:19:in
'
'
I tried to run grails cf-list-files to check tomcat logs but I got the following error:
| Environment set to development..... Error: 400 Bad Request | Error org.cloudfoundry.client.lib.CloudFoundryException: 400 Bad Request (Operation not permitted on a stopped app) | Error at org.cloudfoundry.client.lib.CloudFoundryClient$ErrorHandler.handleError(CloudFoundryClient.java:78) | Error at org.cloudfoundry.client.lib.CloudFoundryClient.getFile(CloudFoundryClient.java:463)
回答1:
As tomas posted on 3/27,
grails install-plugin cloud-foundry followed by grails cf-push
来源:https://stackoverflow.com/questions/9882391/error-310-staging-failed-deploying-grails-app-in-cloud-foundry