bostonember / website

19 stars 7 forks source link

Heroku deployment #1

Open vasilakisfil opened 9 years ago

vasilakisfil commented 9 years ago

Well I know that you don't use Heroku anymore but if you have time I would like to know if it is possible (and how) to deploy such an app (rails + ember-cli) in Heroku...

Sinetheta commented 9 years ago

Ya, that was an unfortunate discovery, to find that deploying a project build into a subdirectory like this one is a non-trivial matter on heroku.

shime commented 9 years ago

Just include the JS app build into Rails application and deploy it like a standard Rails app on Heroku.

Sinetheta commented 9 years ago

@shime that's the "non-trivial" part. You need a deploy process that builds the frontend, checks it in "somewhere" (possibly a branch just for production deployments), then either configure your repo to run despite the fact that the rails app isn't in the root) or use git subtree to push only the /rails directory to heroku.

An example rake task using the second technique is DockYard's ember-cli-plus-backend which accompanies their Building an Ember App with Rails Part.