How does one deploy a rails application on Heroku when the Rails code doesn't sit at the root of the git repository?
We're hoping to bring in a couple of thick javascript clients into the same repository as our rails app to aid with dependency management and interrelated build tools. Ideally, this will result in an git repository with a directory structure that looks like:
/repo
/rails
/app
/config
/ ...
/admin
/..emberstuff
/agent
/..emberstuff
Unfortunately this isn't supported (that I can tell) by default in Heroku.
You can control how the processes spawn using the Procfile in Heroku. You can see that here: https://devcenter.heroku.com/articles/procfile. If you commit a Procfile into your root directory this will control how your app spawns. Bear in mind, you can use shell in your procfile, too. For example:
myprocess: sh -c 'cd ./rails/ && exec name'
as per your structure above.
Hope that helps.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With