Rails Not Finding Rake-10.5.0

Rails not finding rake-10.5.0

I believe the issue was to do with my Ruby install.
I ran the below commands and this seems to have solved the issue

rvm install ruby-2.0.0-p643
rvm --default use 2.0.0
ruby -v
ruby 2.0.0p643 (2015-02-25 revision 49749) [x86_64-darwin14.1.0]

RubyMine: Could not find rake-10.5.0 in any of the sources

I solved my problem by

  1. Uninstall ALL gems, including rails gem:

    gem uninstall -aIx

  2. Re-install rails:

    gem install rails

  3. Then RubyMine somehow don't detect the rails version I just installed, to create a project, run
    rails new projectName
    in the terminal to create a project, and then open the project folder in RubyMine.

How to fix 'An error occurred while installing rake (10.5.0), and Bundler cannot continue.' error

The end problem was caused by locking, from mounting using nfs.

If you're having this problem while using vagrant check this answer from another thread.

It fixed the locking errors for me.

Error Could not find rake-10.5.0 in any of the sources on Phusion Passenger Docker image

This error is due to out of date software. Because the passenger images are not updated frequently it is important to bring everything up to date in your Dockerfile. This is how I generally setup a Dockerfile based off a phusion image:

FROM phusion/passenger-ruby22:0.9.18

ENV SYSTEM_UPDATE=1
RUN apt-get update \
&& apt-get upgrade -y -o Dpkg::Options::="--force-confold" \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

WORKDIR /home/app
COPY Gemfile /home/app/Gemfile
COPY Gemfile.lock /home/app/Gemfile.lock
RUN gem update --system && \
gem update bundler && \
bundle install --jobs 4 --retry 5

# The rest of your app setup here

ENTRYPOINT ["/sbin/my_init", "--"]

SYSTEM_UPDATE is just a cache buster variable. When I bump that up all the packages will be updated on the next docker build. It should be bumped frequently.

I also ensure gem and bundler are fully up to date before running bundle install.

Also, there is no benefit to copying your Gemfile and Gemfile.lock to the tmp directory, just copy it to your application directory.

You can remove your final Clean up APT when done. command - that's really not the right place for that. There should be a single RUN line that runs all the apt-get commands in a single layer.

Take a look at https://docs.docker.com/engine/userguide/eng-image/dockerfile_best-practices/ for the best practices around setting up a Dockerfile, especially the sections about using apt-get.

Bundler::GemNotFound: Could not find rake-10.3.2 in any of the sources

bundle config set --local path 'vendor/cache'

generally fixes it as that is the more common problem. Basically, your bundler path configuration is messed up. See their documentation (first paragraph) for where to find those configurations and change them manually if needed.

rake error cannot find rake file

I was able to resolve this problem with

mkdir -p /usr/share/rubygems-integration/all/gems/rake-10.5.0/bin
ln -s /usr/bin/rake /usr/share/rubygems-integration/all/gems/rake-10.5.0/bin/

See https://github.com/Linuxbrew/brew/pull/477/commits/e5909f11b6de405d9a26191d154f1b650f6f8b41



Related Topics



Leave a reply



Submit