title: Heroku, Problem/Question
body: <p>I was referred to Heroku for Ruby on Rails hosting and so far I think I am really going to like it. Just wondering if I anyone out there can help me figure out what is wrong. </p>
  
  <p>I follow there instructions for creating an app on there site, create and commit git, push the code and it shows up at <a href="http://mylifebattlecry.heroku.com" rel="nofollow noreferrer">http://mylifebattlecry.heroku.com</a> (though the bulk of what I have done is in the /posts/ path) When I go to enter a new "post" (because this is kind of a blog platform) I get the 500.html error and essentially everything shuts down. Can't even get back to the page that I entered the post. </p>
  
  <p>Seems to me something is wrong with the database set up. I did as they suggested including ...$ heroku rake db:migrate, and nothing. </p>
  
  <p>Just wondering if anyone knows off hand what I am doing wrong. Here are the instructions they give for reference:</p>
  
  <p>Install the Heroku gem:sudo gem install herokuCreate a new git repository for your app (if you haven't already):</p>
  
  <pre><code>cd myapp
  git init &amp;&amp; git add . &amp;&amp; git commit -m "first commit"
  </code></pre>
  
  <p>Create a new Heroku app:</p>
  
  <pre><code>heroku create
  Created http://sharp-autumn-42.com/ | git@heroku.com:sharp-autumn-42.git
  Git remote heroku added
  </code></pre>
  
  <p>NOTE: The app's name is generated automatically; don't worry, you can rename it at any time.</p>
  
  <p>Deploy your code:</p>
  
  <pre><code>git push heroku master
  </code></pre>
  
  <p>Run migrations (or other bootstrap tasks):</p>
  
  <pre><code>heroku rake db:migrate
  </code></pre>
  
  <p>Open the deployed app in your browser:
      heroku open</p>
  
  <p>Here is the ..$ heroku logs if it helps:</p>
  
  <pre><code>brandon-gadocis-macbook-pro:mylifebattlecry bgadoci$ heroku logs -app mylifebattlecry
  ==&gt; dyno-629271.log &lt;==
  
  ==&gt; production.log &lt;==
  # Logfile created on Sun Nov 22 18:26:06 -0800 2009
  
  Processing PostsController#index (for 99.7.50.140 at 2009-11-22 18:26:07) [GET]
  Rendering template within layouts/posts
  Rendering posts/index
  
  ActionView::TemplateError (PGError: ERROR:  column votes.post_id does not exist
  LINE 1: SELECT count(*) AS count_all FROM "votes" WHERE ("votes".pos...
                                                           ^
  : SELECT count(*) AS count_all FROM "votes" WHERE ("votes".post_id = 1) ) on line #58 of app/views/posts/index.html.erb:
  55:                 &lt;/div&gt;
  56:             &lt;div id="vote"&gt;&lt;br/&gt;
  57:                 &lt;div id="votes"&gt;
  58:                     &lt;%= pluralize post.votes.count, 'Person' %&gt;  like the above BattleCry. &lt;br/&gt;
  59:                 &lt;/div&gt;
  60:                 &lt;%= link_to "Comments (#{post.comments.count})", post %&gt;
  61:             &lt;/div&gt;
  
      app/views/posts/index.html.erb:58
      app/views/posts/index.html.erb:51
      app/views/posts/index.html.erb:45:in `each'
      app/views/posts/index.html.erb:45
      app/controllers/posts_controller.rb:11:in `index'
      /home/heroku_rack/lib/static_assets.rb:9:in `call'
      /home/heroku_rack/lib/last_access.rb:25:in `call'
      /home/heroku_rack/lib/date_header.rb:14:in `call'
      thin (1.0.1) lib/thin/connection.rb:80:in `pre_process'
      thin (1.0.1) lib/thin/connection.rb:78:in `catch'
      thin (1.0.1) lib/thin/connection.rb:78:in `pre_process'
      thin (1.0.1) lib/thin/connection.rb:57:in `process'
      thin (1.0.1) lib/thin/connection.rb:42:in `receive_data'
      eventmachine (0.12.6) lib/eventmachine.rb:240:in `run_machine'
      eventmachine (0.12.6) lib/eventmachine.rb:240:in `run'
      thin (1.0.1) lib/thin/backends/base.rb:57:in `start'
      thin (1.0.1) lib/thin/server.rb:150:in `start'
      thin (1.0.1) lib/thin/controllers/controller.rb:80:in `start'
      thin (1.0.1) lib/thin/runner.rb:173:in `send'
      thin (1.0.1) lib/thin/runner.rb:173:in `run_command'
      thin (1.0.1) lib/thin/runner.rb:139:in `run!'
      thin (1.0.1) bin/thin:6
      /usr/local/bin/thin:20:in `load'
      /usr/local/bin/thin:20
  
  Rendering /disk1/home/slugs/88382_601a216_9803/mnt/public/500.html (500 Internal Server Error)
  </code></pre>