A
A
Alexander Ivanov2017-10-09 22:46:56
Ruby on Rails
Alexander Ivanov, 2017-10-09 22:46:56

How to fix the problem with installing RoR (beget)?

cannot load such file -- bundler/setup (LoadError)
  /opt/ruby/2.2/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require'
  /opt/ruby/2.2/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require'
  /opt/passenger40/lib/phusion_passenger/loader_shared_helpers.rb:263:in `block in run_load_path_setup_code'
  /opt/passenger40/lib/phusion_passenger/loader_shared_helpers.rb:366:in `running_bundler'
  /opt/passenger40/lib/phusion_passenger/loader_shared_helpers.rb:261:in `run_load_path_setup_code'
  /opt/passenger40/helper-scripts/rack-preloader.rb:100:in `preload_app'
  /opt/passenger40/helper-scripts/rack-preloader.rb:158:in `<module:App>'
  /opt/passenger40/helper-scripts/rack-preloader.rb:29:in `<module:PhusionPassenger>'
  /opt/passenger40/helper-scripts/rack-preloader.rb:28:in `<main>'

https://beget.com/en/articles/webapp_ruby - everything is done as described there
SetENV GEM_HOME /home/e/erveeebbet/.gem/ruby/2.2:/opt/rubies/ruby-2.2/lib/ruby/gems/ 2.2
SetENV GEM_PATH /home/e/erveeebbet/.gem/ruby/2.2:/opt/rubies/ruby-2.2/lib/ruby/gems/2.2
installed version, 2.2 same
____________________________
2.3
gem environment
RubyGems Environment:
  - RUBYGEMS VERSION: 2.5.1
  - RUBY VERSION: 2.3.1 (2016-04-26 patchlevel 112) [x86_64-linux]
  - INSTALLATION DIRECTORY: /home/s/__path__/.gem/ruby/2.3.1
  - USER INSTALLATION DIRECTORY: /home/s/__path__/.gem/ruby/2.3.0
  - RUBY EXECUTABLE: /opt/ruby/2.3/bin/ruby
  - EXECUTABLE DIRECTORY: /home/s/__path__/.gem/ruby/2.3.1/bin
  - SPEC CACHE DIRECTORY: /home/s/__path__/.gem/specs
  - SYSTEM CONFIGURATION DIRECTORY: /opt/ruby/2.3/etc
  - RUBYGEMS PLATFORMS:
    - ruby
    - x86_64-linux
  - GEM PATHS:
     - /home/s/__path__/.gem/ruby/2.3.1
     - /opt/ruby/2.3/lib/ruby/gems/2.3.0
  - GEM CONFIGURATION:
     - :update_sources => true
     - :verbose => true
     - :backtrace => false
     - :bulk_threshold => 1000
  - REMOTE SOURCES:
     - https://rubygems.org/
  - SHELL PATH:
     - /home/s/__path__/.gem/ruby/2.3.1/bin
     - /opt/ruby/2.3/lib/ruby/gems/2.3.0/bin
     - /opt/rubies/ruby-2.3/bin
     - /home/s/__path__/.local/bin
     - /usr/local/bin
     - /usr/bin
     - /bin
     - /usr/games
     - /home/s/__path__/.rvm/bin
     - /home/s/__path__/.rvm/bin

# мои пути

 SetENV GEM_HOME /home/s/__path__/.gem/ruby/2.3.1/bin:/opt/rubies/ruby-2.2/lib/ruby/gems/2.2
 SetENV GEM_PATH /home/s/__path__/.gem/ruby/2.3.1/bin:/opt/rubies/ruby-2.2/lib/ruby/gems/2.2

Answer the question

In order to leave comments, you need to log in

1 answer(s)
R
Roman Mirilaczvili, 2017-10-10
@2ord

Most likely something is tricky with the paths SetENV GEM_HOME, SetENV GEM_PATHor you just need to install the bundler:
gem install bundler

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question