简体   繁体   中英

rbenv: bundle: command not found

I am trying create bosh release using command

bosh create release --force --final --with-tarball

I got following error

Error:  
     > + bundle package --all
     > rbenv: bundle: command not found
     >
     > The `bundle' command exists in these Ruby versions:
     >   2.2.4
     'admin_ui' pre-packaging failed

In my Linux machine following version of software is installed.

which ruby
/root/.rbenv/shims/ruby

ruby --version
ruby 2.2.4p230 (2015-12-16 revision 53155)

which bundle
/root/.rbenv/shims/bundle

bundle --version
Bundler version 1.11.2

Update: ~/.profile file

export PATH="$HOME/.rbenv/bin:$PATH"
eval "$(rbenv init -)"

I source this file before creating bosh release

error:

> Using membrane 0.0.5
  > Installing mime-types-data 3.2015.1120
  >
  > Gem::InstallError: mime-types-data requires Ruby version >= 2.0.

Looks like bosh runs in it's own environment (read: it does not load all your .bashrc etc configs.)

One might try to put what is rbenv -related into ~/.profile file (it should be read by bosh ,) or try another way to tell bosh about the environment.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM