"Bin/Rails: No Such File or Directory" W/ Ruby 2 & Rails 4 on Heroku

bin/rails: No such file or directory w/ Ruby 2 & Rails 4 on Heroku

After struggling with this for a bit, I noticed that my Rails 4 project had a /bin directory, unlike some older Rails 3 projects I had cloned. /bin contains 3 files, bundle, rails, and rake, but these weren't making it to Heroku because I had bin in my global .gitignore file.

This is a pretty common ignore rule if you work with Git and other languages (Java, etc.), so to fix this:

  1. Remove bin from ~/.gitignore
  2. Run bundle install
  3. Commit your
    changes with git add . and git commit -m "Add bin back"
  4. Push your changes to Heroku with git push heroku master

Starting out with ruby: bin/rails: No such file or directory

You have to be in app folder. Do cd *app_name*

Heroku App Crash H10 - bash: bin/rails: No such file or directory

I found a solution to the problem - it's quite simple:

heroku config:set PATH=bin:vendor/bundle/ruby/2.0.0/bin:/usr/local/bin:/usr/bin:/bin

I found the solution here: https://devcenter.heroku.com/articles/ruby-versions

heroku run rake db:migrate: No such file or directory

I've found the solution. Apparently i had to update the files located at bin folder with this command

rake rails:update:bin

Ruby : /app/bin/ruby: No such file or directory - Collector

You should pass a full path to the executable file. If it in the lib directory

collector: bundle exec ruby ./lib/flow.rb -p $PORT


Related Topics



Leave a reply



Submit