Reputation: 862
I'm trying to deploy a Ruby on Rails application to an anynines.com server. Which is based on cloud foundry. They provide a sample app here: https://github.com/anynines/simple_rails_app which I deployed successfully. When I tried to deploy a 'Hello World' App, which worked locally with the built-in server ('rails server' command), I failed (errors were the same as described later on). At this point I should give you some information about the development environment: Ruby v. 1.9.3. Rails v. 4.1.1. Developing on a windows machine.
Then I tried to start from the scratch and created a new default application with "rails new deploytest", which shows you that "Welcome aboard" Screen. Then I created a manifest.yml file like this:
applications:
- name: deploytest
memory: 512m
instances: 1
host: deploytest
domain: de.a9sapp.eu
path: .
Then i executed the "cf push" command. The files were uploaded, builder ran and finally the console promted -----> Uploading droplet (34M). But after that the only thing that happend was this:
0 of 1 instances running, 1 down
0 of 1 instances running, 1 starting
0 of 1 instances running, 1 down
0 of 1 instances running, 1 down
0 of 1 instances running, 1 down
0 of 1 instances running, 1 down
Until it timed out. The logfile says this:
2014-07-24T22:51:20.73+0200 [DEA] OUT Removing crash for app with id 89eb57a 4-f602-4809-9255-c9dd5944a4c1
2014-07-24T22:51:20.73+0200 [DEA] OUT Stopping app instance (index 0) with guid 89eb57a4-f602-4809-9255-c9dd5944a4c1
2014-07-24T22:51:20.73+0200 [DEA] OUT Stopped app instance (index 0) with guid 89eb57a4-f602-4809-9255-c9dd5944a4c1
2014-07-24T22:51:55.05+0200 [DEA] OUT Starting app instance (index 0) with guid 89eb57a4-f602-4809-9255-c9dd5944a4c1
2014-07-24T22:51:58.80+0200 [API] OUT App instance exited with guid 89eb57a4-f602-4809-9255-c9dd5944a4c1 payload: {"cc_partition"=>"default", "droplet"=>"89eb57a4-f602-4809-9255-c9dd5944a4c1", "version"=>"23663797-8b42-44e7-8913-439f1a0553bd","instance"=>"69928ad0f7b54a4aae4ca70f14532d1", "index"=>0, "reason"=>"CRASHED", "exit_status"=>127, "exit_description"=>"appinstance exited", "crash_timestamp"=>1406235118}
I was googling for hours solving this issue, but I did't get the point. I tried to completely remove SQL Information. I Also changed the database.yml and the Gemfile according to the sample project to mysql and use a mysql-service within the server.
I don't see any more differences between the working one and the generated 'default' app. Of course I could just take the sample as a base, but I'd like to know what I'm doing wrong by starting from the scratch. Please tell me that secret, many thanks in advance.
P.S.: This it what 'cf app deploytest' prompts:
requested state: started
instances: 0/1
usage: 512M x 1 instances
urls: deploytest.de.a9sapp.eu
state since cpu memory disk
down 2014-07-24 11:26:10 PM 0.0% 0 of 0 0 of 0
Upvotes: 0
Views: 527
Reputation: 862
It needed a buildpack. Added
buildpack: https://github.com/heroku/heroku-buildpack-ruby.git
to the manifest.yml, respectively run 'cf push -b https://github.com/heroku/heroku-buildpack-ruby.git'
Upvotes: 1