Heroku and Github integration (how to structure the project)

Posted by Noah on Stack Overflow See other posts from Stack Overflow or by Noah
Published on 2010-03-16T13:30:27Z Indexed on 2010/03/16 13:36 UTC
Read the original article Hit count: 714

Filed under:
|
|

I'm creating a webservice and I want to store the source on github and run the app on heroku. I haven't seen my exact scenario addressed anywhere on the 'net so far, so I'll ask it here:

I want to have the following directory structure:

/project
  .git
  README <-- project readme file
  TODO.otl <-- project outline
  ... <-- other project-related stuff
  /my_rails_app
     app
     config
     ...
     README <-- rails' readme file 

In the above, project corresponds to http://github.com/myuser/project, and my_rails_app is the code that should be pushed to heroku. Do I need a separate branch for the rails app, or is there a simpler way that I'm missing?

I guess my project-related non-rails files could live in my_rails_app, but the rails README already lives there and it seems inconsistent to overwrite that. However, if I leave it, my github page for the rails app will contain the rails readme, which makes no sense.

Thanks,

Noah

P.S. I tried just setting it up as described above and running

git push heroku

from the main project folder. Of course, heroku doesn't know I want to deploy the subfolder:

-----> Heroku receiving push
 !     Heroku push rejected, no Rails or Rack app detected.

© Stack Overflow or respective owner

Related posts about heroku

Related posts about deployment